Leap0

Create a presigned URL

Create a temporary public URL for a specific sandbox port. The returned `token` is only returned once and is stored server-side as a SHA-256 hash. The URL resolves to `https://<token>.leap0.app` in production, or the matching environment-specific presigned domain in non-production stacks.

POST
/v1/sandbox/{sandboxID}/presigned-url

Create a temporary public URL for a specific sandbox port. The returned token is only returned once and is stored server-side as a SHA-256 hash.

The URL resolves to https://<token>.leap0.app in production, or the matching environment-specific presigned domain in non-production stacks.

Authorization

BearerAuth
AuthorizationBearer <token>

API key passed as a Bearer token in the Authorization header. Alternatively, use the leap0-authorization header.

In: header

Path Parameters

sandboxID*string

Unique sandbox identifier.

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

port*integer

Sandbox port exposed through the public URL.

Range1 <= value <= 65535
expires_in?integer

Optional TTL in seconds. Defaults to 3600.

Formatint64
Range1 <= value

Response Body

application/json

application/json

application/json

application/json

curl -X POST "https://api.leap0.dev/v1/sandbox/string/presigned-url" \  -H "Content-Type: application/json" \  -d '{    "port": 8080  }'
{  "id": "psu-abc123",  "token": "string",  "url": "https://abcdef1234567890.leap0.app",  "sandbox_id": "string",  "port": 1,  "expires_at": "2019-08-24T14:15:22Z",  "created_at": "2019-08-24T14:15:22Z"}
{  "message": "string",  "errors": [    {      "field": "string",      "error": "string"    }  ]}
{  "message": "string"}
{  "message": "string"}