Skip to main content

Sandbox API

API to set up pipeline connections between epilot orgs to sync and promote configurations (from sandbox to production and vice-versa)

Quick Startโ€‹

# List available operations
epilot sandbox

# Call an operation
epilot sandbox listPipelines

Common Flagsโ€‹

FlagDescription
-p key=valueSet a named parameter
-d '{...}'Request body JSON
-H 'Key: Value'Custom header
-t, --token <token>Bearer token for authentication
--profile <name>Use a named profile
-s, --server <url>Override server base URL
-i, --includeInclude response headers in output
--jsonOutput raw JSON (no formatting)
-v, --verboseVerbose output (show request details)
--jsonata <expr>JSONata expression to transform response
--definition <file>Override OpenAPI spec file/URL
--guidedPrompt for all parameters interactively
--no-interactiveDisable interactive prompts

Operationsโ€‹

Pipelines

  • listPipelines โ€” List pipelines the current organization is part of
  • createPipeline โ€” Create a new pipeline by passing an api token from another organization.
  • getPipeline โ€” Get pipeline by ID
  • deletePipeline โ€” Delete a pipeline by ID
  • generatePipelineToken โ€” Generate a temporary pipeline access token to access the other org from the pipeline

Sandbox Requests

listPipelinesโ€‹

List pipelines the current organization is part of

GET /v1/sandbox/pipelines

Sample Call

epilot sandbox listPipelines

With JSONata filter:

epilot sandbox listPipelines --jsonata 'results[0]'
Sample Response
{
"results": [
{
"pipeline_role": "sandbox",
"pipeline_id": "12345::54321",
"sandbox_org_id": "12345",
"sandbox_org_name": "Sandbox",
"production_org_id": "54321",
"production_org_name": "Production",
"created_at": "1970-01-01T00:00:00.000Z"
}
],
"total": 1
}

createPipelineโ€‹

Create a new pipeline by passing an api token from another organization.

POST /v1/sandbox/pipelines

Request Body

Sample Call

epilot sandbox createPipeline \
-d '{"pipeline_role":"sandbox","api_token":"eyJhbGciOiJIUzI1NiIs..."}'

Using stdin pipe:

cat body.json | epilot sandbox createPipeline

With JSONata filter:

epilot sandbox createPipeline --jsonata '$'
Sample Response
{
"pipeline_role": "sandbox",
"pipeline_id": "12345::54321",
"sandbox_org_id": "12345",
"sandbox_org_name": "Sandbox",
"production_org_id": "54321",
"production_org_name": "Production",
"created_at": "1970-01-01T00:00:00.000Z"
}

getPipelineโ€‹

Get pipeline by ID

GET /v1/sandbox/pipelines/{pipeline_id}

Parameters

NameInTypeRequiredDescription
pipeline_idpathstringYes

Sample Call

epilot sandbox getPipeline \
-p pipeline_id=12345::54321

Using positional args for path parameters:

epilot sandbox getPipeline 12345::54321

With JSONata filter:

epilot sandbox getPipeline -p pipeline_id=12345::54321 --jsonata '$'
Sample Response
{
"pipeline_role": "sandbox",
"pipeline_id": "12345::54321",
"sandbox_org_id": "12345",
"sandbox_org_name": "Sandbox",
"production_org_id": "54321",
"production_org_name": "Production",
"created_at": "1970-01-01T00:00:00.000Z"
}

deletePipelineโ€‹

Delete a pipeline by ID

DELETE /v1/sandbox/pipelines/{pipeline_id}

Parameters

NameInTypeRequiredDescription
pipeline_idpathstringYes

Sample Call

epilot sandbox deletePipeline \
-p pipeline_id=12345::54321

Using positional args for path parameters:

epilot sandbox deletePipeline 12345::54321

With JSONata filter:

epilot sandbox deletePipeline -p pipeline_id=12345::54321 --jsonata '$'
Sample Response
{
"pipeline_role": "sandbox",
"pipeline_id": "12345::54321",
"sandbox_org_id": "12345",
"sandbox_org_name": "Sandbox",
"production_org_id": "54321",
"production_org_name": "Production",
"created_at": "1970-01-01T00:00:00.000Z"
}

generatePipelineTokenโ€‹

Generate a temporary pipeline access token to access the other org from the pipeline

GET /v1/sandbox/pipelines/{pipeline_id}/token

Parameters

NameInTypeRequiredDescription
pipeline_idpathstringYes

Sample Call

epilot sandbox generatePipelineToken \
-p pipeline_id=12345::54321

Using positional args for path parameters:

epilot sandbox generatePipelineToken 12345::54321

With JSONata filter:

epilot sandbox generatePipelineToken -p pipeline_id=12345::54321 --jsonata 'pipeline_token'
Sample Response
{
"pipeline_token": "eyJhbGciOiJIUzI1NiIs..."
}

requestSandboxโ€‹

Request a sandbox account for a user

POST /v1/sandbox:request

Request Body

Sample Call

epilot sandbox requestSandbox

With request body:

epilot sandbox requestSandbox \
-d '{
"id": 12345,
"fullname": "John Doe",
"company_name": "Company Name",
"position": "Software Engineer",
"email": "user@example.com",
"sandbox_usecase": "Build a payment integration",
"status": "pending",
"connected_to_existing_epilot_customer": true,
"requested_at": "2022-01-01T00:00:00Z",
"sandbox_request_category": "APP_DEVELOPER_ACCOUNT"
}'

Using stdin pipe:

cat body.json | epilot sandbox requestSandbox

With JSONata filter:

epilot sandbox requestSandbox --jsonata 'id'
Sample Response
{
"id": 12345,
"fullname": "John Doe",
"company_name": "Company Name",
"position": "Software Engineer",
"email": "user@example.com",
"sandbox_usecase": "Build a payment integration",
"status": "pending",
"connected_to_existing_epilot_customer": true,
"requested_at": "2022-01-01T00:00:00Z",
"sandbox_request_category": "APP_DEVELOPER_ACCOUNT"
}

listSandboxRequestsโ€‹

List sandbox requests from users

GET /v1/sandbox/requests

Sample Call

epilot sandbox listSandboxRequests

With JSONata filter:

epilot sandbox listSandboxRequests --jsonata 'results[0]'
Sample Response
{
"results": [
{
"id": 12345,
"fullname": "John Doe",
"company_name": "Company Name",
"position": "Software Engineer",
"email": "user@example.com",
"sandbox_usecase": "Build a payment integration",
"status": "pending",
"connected_to_existing_epilot_customer": true,
"requested_at": "2022-01-01T00:00:00Z",
"sandbox_request_category": "APP_DEVELOPER_ACCOUNT"
}
],
"total": 1
}