API

RepositoryImportSessionSelection

Operations

Every route this entity exposes. Each route links to its own reference on this page.

Method Route SDK operation Returns
POST /api/v1/repository_import_sessions/{id}/selections create Success

Examples

One example per SDK, generated from the API model. The argument names are the parameters and fields of this entity, and the values are placeholders. The examples are not compiled or executed.

Golang

Construct client as shown in the Golang setup, then call the operations:

created, err := client.RepositoryImportSessionSelection(nil).Create(map[string]any{"repository_import_session_id": "example", "repositories": "example"}, nil)
if err != nil {
    panic(err)
}
fmt.Println(created)

Lua

Construct client as shown in the Lua setup, then call the operations:

local created, err = client:RepositoryImportSessionSelection():create({ repository_import_session_id = "example", repositories = "example" })

PHP

Construct client as shown in the PHP setup, then call the operations:

$created = $client->RepositoryImportSessionSelection()->create(["repository_import_session_id" => "example", "repositories" => "example"]);

Python

Construct client as shown in the Python setup, then call the operations:

created = client.RepositoryImportSessionSelection().create({ "repository_import_session_id": "example", "repositories": "example" })

Ruby

Construct client as shown in the Ruby setup, then call the operations:

created = client.RepositoryImportSessionSelection.create({ "repository_import_session_id" => "example", "repositories" => "example" })

TypeScript

Construct client as shown in the TypeScript setup, then call the operations:

const created = await client.RepositoryImportSessionSelection().create({ repository_import_session_id: "example", repositories: "example" })

Fields

Field Type Required Description
repositories any Yes Repositories

create

POST /api/v1/repository_import_sessions/{id}/selections

Operation ID: selections_api_v1_repository_import_session.

Authentication: bearer token (bearerAuth).

Parameters

Parameter In Type Required Description
id path string Yes

Request body

application/json

Property Type Required Description
repositories enum: all or array of object Yes

Responses

200: Success

application/json

The response is object.

201: Repository import session

application/json

Property Type Required Description
action_required enum: github_app_installation No
authorization_endpoint string No
can_authorize_github boolean Yes
client_name string Yes
client_version string Yes
created_at string (date-time) Yes
error_message string Yes
expires_at string (date-time) Yes
git_imports array of object Yes
git_imports[].error string No
git_imports[].git_status enum: receiving, durable Yes
git_imports[].git_url string Yes
git_imports[].id string Yes
git_imports[].native_status enum: pending, running, ready, failed, canceled Yes
git_imports[].organization string Yes
git_imports[].repository_id string No
git_imports[].root_path string Yes
git_imports[].slug string Yes
git_imports[].source_branch string Yes
git_imports[].target_branch string Yes
github_app_installation_id string Yes
github_connected boolean Yes
id string Yes
organization_id string Yes
organization_slug string Yes
status enum: pending, running, completed, failed, canceled, expired Yes
updated_at string (date-time) Yes
401: Unauthorized
403: Forbidden
404: Not found
422: Unprocessable entity
502: Bad gateway