Skip to content

Latest commit

 

History

History
298 lines (205 loc) · 11 KB

File metadata and controls

298 lines (205 loc) · 11 KB

Workspaces

(workspaces)

Overview

Available Operations

create_or_update_workspace_o_auth_credentials

Create/update a set of OAuth credentials to override the Airbyte-provided OAuth credentials used for source/destination OAuth. In order to determine what the credential configuration needs to be, please see the connector specification of the relevant source/destination.

Example Usage

import airbyte_api
from airbyte_api import api, models

s = airbyte_api.AirbyteAPI(
    security=models.Security(
        basic_auth=models.SchemeBasicAuth(
            password='',
            username='',
        ),
    ),
)


res = s.workspaces.create_or_update_workspace_o_auth_credentials(request=api.CreateOrUpdateWorkspaceOAuthCredentialsRequest(
    workspace_o_auth_credentials_request=models.WorkspaceOAuthCredentialsRequest(
        actor_type=models.ActorTypeEnum.DESTINATION,
        configuration={
            'user': 'charles',
        },
        name=models.OAuthActorNames.AMAZON_ADS,
    ),
    workspace_id='<value>',
))

if res is not None:
    # handle response
    pass

Parameters

Parameter Type Required Description
request api.CreateOrUpdateWorkspaceOAuthCredentialsRequest ✔️ The request object to use for the request.

Response

api.CreateOrUpdateWorkspaceOAuthCredentialsResponse

Errors

Error Type Status Code Content Type
errors.SDKError 4XX, 5XX */*

create_workspace

Create a workspace

Example Usage

import airbyte_api
from airbyte_api import models

s = airbyte_api.AirbyteAPI(
    security=models.Security(
        basic_auth=models.SchemeBasicAuth(
            password='',
            username='',
        ),
    ),
)


res = s.workspaces.create_workspace(request=models.WorkspaceCreateRequest(
    name='Company Workspace Name',
))

if res.workspace_response is not None:
    # handle response
    pass

Parameters

Parameter Type Required Description
request models.WorkspaceCreateRequest ✔️ The request object to use for the request.

Response

api.CreateWorkspaceResponse

Errors

Error Type Status Code Content Type
errors.SDKError 4XX, 5XX */*

delete_workspace

Delete a Workspace

Example Usage

import airbyte_api
from airbyte_api import api, models

s = airbyte_api.AirbyteAPI(
    security=models.Security(
        basic_auth=models.SchemeBasicAuth(
            password='',
            username='',
        ),
    ),
)


res = s.workspaces.delete_workspace(request=api.DeleteWorkspaceRequest(
    workspace_id='<value>',
))

if res is not None:
    # handle response
    pass

Parameters

Parameter Type Required Description
request api.DeleteWorkspaceRequest ✔️ The request object to use for the request.

Response

api.DeleteWorkspaceResponse

Errors

Error Type Status Code Content Type
errors.SDKError 4XX, 5XX */*

get_workspace

Get Workspace details

Example Usage

import airbyte_api
from airbyte_api import api, models

s = airbyte_api.AirbyteAPI(
    security=models.Security(
        basic_auth=models.SchemeBasicAuth(
            password='',
            username='',
        ),
    ),
)


res = s.workspaces.get_workspace(request=api.GetWorkspaceRequest(
    workspace_id='<value>',
))

if res.workspace_response is not None:
    # handle response
    pass

Parameters

Parameter Type Required Description
request api.GetWorkspaceRequest ✔️ The request object to use for the request.

Response

api.GetWorkspaceResponse

Errors

Error Type Status Code Content Type
errors.SDKError 4XX, 5XX */*

list_workspaces

List workspaces

Example Usage

import airbyte_api
from airbyte_api import api, models

s = airbyte_api.AirbyteAPI(
    security=models.Security(
        basic_auth=models.SchemeBasicAuth(
            password='',
            username='',
        ),
    ),
)


res = s.workspaces.list_workspaces(request=api.ListWorkspacesRequest())

if res.workspaces_response is not None:
    # handle response
    pass

Parameters

Parameter Type Required Description
request api.ListWorkspacesRequest ✔️ The request object to use for the request.

Response

api.ListWorkspacesResponse

Errors

Error Type Status Code Content Type
errors.SDKError 4XX, 5XX */*

update_workspace

Update a workspace

Example Usage

import airbyte_api
from airbyte_api import api, models

s = airbyte_api.AirbyteAPI(
    security=models.Security(
        basic_auth=models.SchemeBasicAuth(
            password='',
            username='',
        ),
    ),
)


res = s.workspaces.update_workspace(request=api.UpdateWorkspaceRequest(
    workspace_update_request=models.WorkspaceUpdateRequest(
        name='Company Workspace Name',
    ),
    workspace_id='<value>',
))

if res.workspace_response is not None:
    # handle response
    pass

Parameters

Parameter Type Required Description
request api.UpdateWorkspaceRequest ✔️ The request object to use for the request.

Response

api.UpdateWorkspaceResponse

Errors

Error Type Status Code Content Type
errors.SDKError 4XX, 5XX */*