API

OrganizationSite

Operations

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

Method Route SDK operation Returns
POST /api/v1/spark/organizations/{organization_id}/sites/{name}/token create Success
POST /api/v1/spark/organizations/{organization_id}/sites create Success
GET /api/v1/spark/organizations/{organization_id}/sites load Success
DELETE /api/v1/spark/organizations/{organization_id}/sites/{name} remove Success
DELETE /api/v1/spark/organizations/{organization_id}/sites/{name}/app remove Success
PATCH /api/v1/spark/organizations/{organization_id}/sites/{name} update Success
PUT /api/v1/spark/organizations/{organization_id}/sites/{name}/app update Success
PUT /api/v1/spark/organizations/{organization_id}/sites/{name}/marketplace_template update 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:

organization_site, err := client.OrganizationSite(nil).Load(map[string]any{"organization_id": "example", "native_agent_id": "example"}, nil)
if err != nil {
    panic(err)
}
fmt.Println(organization_site)
created, err := client.OrganizationSite(nil).Create(map[string]any{"organization_id": "example"}, nil)
if err != nil {
    panic(err)
}
fmt.Println(created)
updated, err := client.OrganizationSite(nil).Update(map[string]any{"organization_id": "example"}, nil)
if err != nil {
    panic(err)
}
fmt.Println(updated)
removed, err := client.OrganizationSite(nil).Remove(map[string]any{"id": "example", "organization_id": "example"}, nil)
if err != nil {
    panic(err)
}
fmt.Println(removed)

Lua

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

local organization_site, err = client:OrganizationSite():load({ organization_id = "example", native_agent_id = "example" })
local created, err = client:OrganizationSite():create({ organization_id = "example" })
local updated, err = client:OrganizationSite():update({ organization_id = "example" })
local removed, err = client:OrganizationSite():remove({ id = "example", organization_id = "example" })

PHP

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

$organization_site = $client->OrganizationSite()->load(["organization_id" => "example", "native_agent_id" => "example"]);
$created = $client->OrganizationSite()->create(["organization_id" => "example"]);
$updated = $client->OrganizationSite()->update(["organization_id" => "example"]);
$client->OrganizationSite()->remove(["id" => "example", "organization_id" => "example"]);

Python

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

organization_site = client.OrganizationSite().load({"organization_id": "example", "native_agent_id": "example"})
created = client.OrganizationSite().create({ "organization_id": "example" })
updated = client.OrganizationSite().update({"organization_id": "example"})
client.OrganizationSite().remove({"id": "example", "organization_id": "example"})

Ruby

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

organization_site = client.OrganizationSite.load({ "organization_id" => "example", "native_agent_id" => "example" })
created = client.OrganizationSite.create({ "organization_id" => "example" })
updated = client.OrganizationSite.update({ "organization_id" => "example" })
client.OrganizationSite.remove({ "id" => "example", "organization_id" => "example" })

TypeScript

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

const organization_site = await client.OrganizationSite().load({ organization_id: "example", native_agent_id: "example" })
const created = await client.OrganizationSite().create({ organization_id: "example" })
const updated = await client.OrganizationSite().update({ organization_id: "example" })
await client.OrganizationSite().remove({ id: "example", organization_id: "example" })

Fields

Field Type Required Description
id string No Id

create

POST /api/v1/spark/organizations/{organization_id}/sites/{name}/token

Operation ID: post_api_v1_spark_organizations_organization_id_sites_name_token.

Authentication: bearer token (bearerAuth).

Parameters

Parameter In Type Required Description
organization_id path string Yes
name path string Yes

Request body

application/json

The request body is object.

Responses

200: Success

application/json

The response is object.

401: Unauthorized
403: Forbidden
404: Not found
422: Unprocessable entity
502: Bad gateway

POST /api/v1/spark/organizations/{organization_id}/sites

Operation ID: post_api_v1_spark_organizations_organization_id_sites.

Authentication: bearer token (bearerAuth).

Parameters

Parameter In Type Required Description
organization_id path string Yes

Request body

application/json

The request body is object.

Responses

200: Success

application/json

The response is object.

401: Unauthorized
403: Forbidden
404: Not found
422: Unprocessable entity
502: Bad gateway

load

GET /api/v1/spark/organizations/{organization_id}/sites

Operation ID: get_api_v1_spark_organizations_organization_id_sites.

Authentication: bearer token (bearerAuth).

Parameters

Parameter In Type Required Description
organization_id path string Yes
native_agent_id query string Yes The calling agent's native id

Responses

200: Success

application/json

The response is object.

401: Unauthorized
403: Forbidden
404: Not found
422: Unprocessable entity
502: Bad gateway

remove

DELETE /api/v1/spark/organizations/{organization_id}/sites/{name}

Operation ID: delete_api_v1_spark_organizations_organization_id_sites_name_.

Authentication: bearer token (bearerAuth).

Parameters

Parameter In Type Required Description
organization_id path string Yes
name path string Yes

Responses

200: Success

application/json

The response is object.

401: Unauthorized
403: Forbidden
404: Not found
422: Unprocessable entity
502: Bad gateway

DELETE /api/v1/spark/organizations/{organization_id}/sites/{name}/app

Operation ID: delete_api_v1_spark_organizations_organization_id_sites_name_app.

Authentication: bearer token (bearerAuth).

Parameters

Parameter In Type Required Description
organization_id path string Yes
name path string Yes

Responses

200: Success

application/json

The response is object.

401: Unauthorized
403: Forbidden
404: Not found
422: Unprocessable entity
502: Bad gateway

update

PATCH /api/v1/spark/organizations/{organization_id}/sites/{name}

Operation ID: patch_api_v1_spark_organizations_organization_id_sites_name_.

Authentication: bearer token (bearerAuth).

Parameters

Parameter In Type Required Description
organization_id path string Yes
name path string Yes

Request body

application/json

The request body is object.

Responses

200: Success

application/json

The response is object.

401: Unauthorized
403: Forbidden
404: Not found
422: Unprocessable entity
502: Bad gateway

PUT /api/v1/spark/organizations/{organization_id}/sites/{name}/app

Operation ID: put_api_v1_spark_organizations_organization_id_sites_name_app.

Authentication: bearer token (bearerAuth).

Parameters

Parameter In Type Required Description
organization_id path string Yes
name path string Yes

Request body

application/json

The request body is object.

Responses

200: Success

application/json

The response is object.

401: Unauthorized
403: Forbidden
404: Not found
422: Unprocessable entity
502: Bad gateway

PUT /api/v1/spark/organizations/{organization_id}/sites/{name}/marketplace_template

Operation ID: put_api_v1_spark_organizations_organization_id_sites_name_marketplace_template.

Authentication: bearer token (bearerAuth).

Parameters

Parameter In Type Required Description
organization_id path string Yes
name path string Yes

Request body

application/json

The request body is object.

Responses

200: Success

application/json

The response is object.

401: Unauthorized
403: Forbidden
404: Not found
422: Unprocessable entity
502: Bad gateway