diff --git a/airbyte-api/src/main/openapi/config.yaml b/airbyte-api/src/main/openapi/config.yaml index eab20dda468..4f697d3a03d 100644 --- a/airbyte-api/src/main/openapi/config.yaml +++ b/airbyte-api/src/main/openapi/config.yaml @@ -4827,6 +4827,7 @@ paths: text/html: {} description: Redirects to documentation operationId: getDocumentation + x-sdk-alias: getDocumentation summary: "Root path, currently returns a redirect to the documentation" # This redirect route is unsecured since it points to our documentation. security: [] @@ -4842,6 +4843,7 @@ paths: summary: Health Check # This route is unsecured for external monitoring. security: [] + x-sdk-alias: getHealthCheck /public/v1/jobs: get: tags: @@ -4953,6 +4955,7 @@ paths: description: Not allowed operationId: listJobs summary: List Jobs by sync type + x-sdk-alias: listJobs post: requestBody: content: @@ -4988,6 +4991,7 @@ paths: description: Not allowed operationId: publicCreateJob summary: Trigger a sync or reset job of a connection + x-sdk-alias: createJob /public/v1/jobs/{jobId}: get: tags: @@ -5012,6 +5016,7 @@ paths: "404": description: Not found operationId: getJob + x-sdk-alias: getJob summary: Get Job status and details delete: tags: @@ -5030,6 +5035,7 @@ paths: "404": description: Not found operationId: publicCancelJob + x-sdk-alias: cancelJob summary: Cancel a running Job parameters: - name: jobId @@ -5056,6 +5062,7 @@ paths: "404": description: Not found operationId: listSources + x-sdk-alias: listSources summary: List sources parameters: - name: workspaceIds @@ -5129,6 +5136,7 @@ paths: "403": description: Not allowed operationId: publicCreateSource + x-sdk-alias: createSource summary: Create a source description: "Creates a source given a name, workspace id, and a json blob containing the configuration for the source." /public/v1/sources/{sourceId}: @@ -5156,6 +5164,7 @@ paths: "404": description: Not found operationId: publicGetSource + x-sdk-alias: getSource summary: Get Source details patch: tags: @@ -5197,6 +5206,7 @@ paths: "404": description: Not found operationId: patchSource + x-sdk-alias: patchSource summary: Update a Source put: tags: @@ -5238,6 +5248,7 @@ paths: "404": description: Not found operationId: putSource + x-sdk-alias: putSource summary: Update a Source and fully overwrite it x-sdk-entity-operation: Source#update delete: @@ -5253,6 +5264,7 @@ paths: "404": description: Not found operationId: publicDeleteSource + x-sdk-alias: deleteSource summary: Delete a Source parameters: - name: sourceId @@ -5279,6 +5291,7 @@ paths: "404": description: Not found operationId: listDestinations + x-sdk-alias: listDestinations summary: List destinations parameters: - name: workspaceIds @@ -5359,6 +5372,7 @@ paths: "404": description: Not found operationId: publicCreateDestination + x-sdk-alias: createDestination summary: Create a destination description: "Creates a destination given a name, workspace id, and a json blob containing the configuration for the source." /public/v1/destinations/{destinationId}: @@ -5391,6 +5405,7 @@ paths: "404": description: Not found operationId: publicGetDestination + x-sdk-alias: getDestination summary: Get Destination details delete: tags: @@ -5405,6 +5420,7 @@ paths: "404": description: Not found operationId: publicDeleteDestination + x-sdk-alias: deleteDestination summary: Delete a Destination patch: tags: @@ -5449,6 +5465,7 @@ paths: "404": description: Not found operationId: patchDestination + x-sdk-alias: patchDestination summary: Update a Destination put: tags: @@ -5493,6 +5510,7 @@ paths: "404": description: Not found operationId: putDestination + x-sdk-alias: putDestination summary: Update a Destination and fully overwrite it x-sdk-entity-operation: Destination#update parameters: @@ -5521,6 +5539,7 @@ paths: "302": description: Redirect to the URL requested in the initiate call with the created secret ID. operationId: oauthCallback + x-sdk-alias: oauthCallback summary: Receive OAuth callbacks description: Redirected to by identity providers after authentication. # This route is unsecured because it's an OAuth callback. @@ -5545,6 +5564,7 @@ paths: "403": description: API key is invalid. operationId: initiateOAuth + x-sdk-alias: initiateOAuth summary: Initiate OAuth for a source description: >- Given a source ID, workspace ID, and redirect URL, initiates OAuth for the source. @@ -5591,6 +5611,7 @@ paths: "403": description: Not allowed operationId: publicCreateConnection + x-sdk-alias: createConnection summary: Create a connection x-sdk-entity-operation: Connection#create get: @@ -5610,6 +5631,7 @@ paths: "404": description: Not found operationId: listConnections + x-sdk-alias: listConnections summary: List connections x-sdk-entity-operation: Connection#list parameters: @@ -5671,6 +5693,7 @@ paths: "404": description: Not found operationId: publicGetConnection + x-sdk-alias: getConnection summary: Get Connection details x-sdk-entity-operation: Connection#read patch: @@ -5709,6 +5732,7 @@ paths: "404": description: Not found operationId: patchConnection + x-sdk-alias: patchConnection summary: Update Connection details x-sdk-entity-operation: Connection#update delete: @@ -5724,6 +5748,7 @@ paths: "404": description: Not found operationId: publicDeleteConnection + x-sdk-alias: deleteConnection summary: Delete a Connection x-sdk-entity-operation: Connection#delete parameters: @@ -5753,6 +5778,7 @@ paths: "404": description: Not found operationId: getStreamProperties + x-sdk-alias: getStreamProperties summary: Get stream properties parameters: - name: "sourceId" @@ -5794,6 +5820,7 @@ paths: "404": description: Not found operationId: publicListWorkspaces + x-sdk-alias: listWorkspaces summary: List workspaces x-sdk-entity-operation: Workspace#list parameters: @@ -5861,6 +5888,7 @@ paths: "403": description: Not allowed operationId: publicCreateWorkspace + x-sdk-alias: createWorkspace summary: Create a workspace x-sdk-entity-operation: Workspace#create /public/v1/workspaces/{workspaceId}: @@ -5894,6 +5922,7 @@ paths: "404": description: Not found operationId: publicGetWorkspace + x-sdk-alias: getWorkspace summary: Get Workspace details x-sdk-entity-operation: Workspace#read patch: @@ -5927,6 +5956,7 @@ paths: "403": description: Not allowed operationId: publicUpdateWorkspace + x-sdk-alias: updateWorkspace summary: Update a workspace x-sdk-entity-operation: Workspace#update delete: @@ -5942,6 +5972,7 @@ paths: "404": description: Not found operationId: publicDeleteWorkspace + x-sdk-alias: deleteWorkspace summary: Delete a Workspace x-sdk-entity-operation: Workspace#delete /public/v1/workspaces/{workspaceId}/oauthCredentials: @@ -5964,6 +5995,7 @@ paths: "403": description: API key is invalid. operationId: createOrUpdateWorkspaceOAuthCredentials + x-sdk-alias: createOrUpdateWorkspaceOAuthCredentials summary: Create OAuth override credentials for a workspace and source type. description: >- Create/update a set of OAuth credentials to override the Airbyte-provided OAuth credentials used for source/destination OAuth. @@ -6015,6 +6047,7 @@ paths: "403": description: Not allowed operationId: publicCreatePermission + x-sdk-alias: createPermission summary: Create a permission x-sdk-entity-operation: Permission#create @@ -10213,8 +10246,10 @@ components: # OAuth OAuthConfiguration: description: The values required to configure OAuth flows. The schema for this must match the `OAuthConfigSpecification.oauthUserInputFromConnectorConfigSpecification` schema. + x-sdk-component: true OAuthInputConfiguration: $ref: "#/components/schemas/OAuthConfiguration" + x-sdk-component: true AdvancedAuth: type: object properties: @@ -12359,28 +12394,24 @@ components: application/json: schema: $ref: "#/components/schemas/NotFoundKnownExceptionInfo" - x-sdk-component: true InvalidInputResponse: description: Input failed validation content: application/json: schema: $ref: "#/components/schemas/InvalidInputExceptionInfo" - x-sdk-component: true ForbiddenResponse: description: Operation forbidden content: application/json: schema: $ref: "#/components/schemas/KnownExceptionInfo" - x-sdk-component: true ExceptionResponse: description: Exception occurred; see message for details. content: application/json: schema: $ref: "#/components/schemas/KnownExceptionInfo" - x-sdk-component: true InitiateOauthResponse: content: application/json: {} diff --git a/airbyte-commons/src/main/java/io/airbyte/commons/json/Jsons.java b/airbyte-commons/src/main/java/io/airbyte/commons/json/Jsons.java index 1e7b141116b..71d17ba6f5a 100644 --- a/airbyte-commons/src/main/java/io/airbyte/commons/json/Jsons.java +++ b/airbyte-commons/src/main/java/io/airbyte/commons/json/Jsons.java @@ -600,6 +600,16 @@ public static Map deserializeToStringMap(final JsonNode json) { return OBJECT_MAPPER.convertValue(json, new TypeReference<>() {}); } + /** + * Convert a {@link JsonNode} as a string-to-string map. + * + * @param json to convert + * @return json as string-to-string map + */ + public static Map deserializeToMap(final JsonNode json) { + return OBJECT_MAPPER.convertValue(json, new TypeReference<>() {}); + } + /** * By the Jackson DefaultPrettyPrinter prints objects with an extra space as follows: {"name" : * "airbyte"}. We prefer {"name": "airbyte"}.