Skip to Content
Docs
API referencePlatform API

Unclaimed instances

POST
/unclaimed-instances

Create a development instance with no account: a project in Pontive's holding workspace with its Development instance, a developer secret key named keyless and an app, everything an app needs to run on the developer's machine. Public and unauthenticated: it takes no credential, and one sent is ignored. The instance is deleted with its users 7 days after it is created (expires_at) unless it is claimed into a workspace first (POST /unclaimed-instances/{instance_id}/claim-links). At most 3 per IP address (IPv6 /64) per rolling 24 hours and a ceiling per ASN (429 unclaimed_instance_limit with Retry-After); 503 unclaimed_instances_unavailable with Retry-After when the service is switched off or a global cap is reached; 403 caller_blocked for a blocked address or network. With X-Idempotency-Key, a retry within 24 hours from the same address answers the same instance, counted once, with fresh secrets: the earlier claim token, key value and client secret stop working. The region is the body's, else the one nearest the caller, echoed back. Redirect URIs are loopback only (422 redirect_uri_not_loopback); a URI without a port matches any port. With encryption_key (a public EC P-256 or OKP X25519 JWK; 422 invalid_encryption_key otherwise) the secrets come back as a compact JWE in encrypted_secrets (ECDH-ES, A256GCM, kid the key's RFC 7638 thumbprint) of {client_secret, secret_key, claim_token}, never in the clear. The secrets are answered once; never log them. The response carries Sunset and Link rel=sunset.

Header Parameters

X-Idempotency-Key?string

Idempotency key: a retry within 24 hours from the same address answers the same instance

Request Body

The instance; every field is optional

application/json
  1. body

The instance; every field is optional

app?

The app made with the instance.

client?

The tool, its version and, when detected, the agent: metrics and abuse signals only, never trusted for limits.

encryption_key?

A public JWK, EC P-256 or OKP X25519: the secrets are then answered sealed to it in encrypted_secrets, never in the clear.

name?string

The project's name, "Untitled app" by default; the claimer may rename it.

region?string

A region this installation serves; by default the one nearest the caller, echoed in the response. Immutable.

Value in"us""eu""au"
tenancy_mode?string

b2c by default. Immutable.

Value in"b2b""b2c"

Response Body

Created

application/json
  1. response
app_id?string
claim_token?string

The instance's ownership until it is claimed, answered once; absent with encryption_key. Never put it in a URL or a log.

client_secret?string

A web app's client secret; absent for spa and native, and with encryption_key.

encrypted_secrets?string

With encryption_key: a compact JWE (ECDH-ES, A256GCM, kid the key's RFC 7638 thumbprint) of {client_secret, secret_key, claim_token}.

environment?string
expires_at?string

When Pontive deletes it, with its users, unless it is claimed first.

Formatdate-time
instance_id?string
issuer?string

The instance's issuer, its auth domain's origin.

limits_url?string
name?string
object?string
project_id?string
region?string
Value in"us""eu""au"
secret_key?string

The developer secret key named keyless; absent with encryption_key.

secret_key_id?string
tenancy_mode?string
Value in"b2b""b2c"
Example Request
curl -X POST 'https://api.pontive.com/v1/unclaimed-instances' \  -H 'Content-Type: application/json' \  -d '{}'
Example Response
{  "app_id": "string",  "claim_token": "string",  "client_secret": "string",  "encrypted_secrets": "string",  "environment": "string",  "expires_at": "2019-08-24T14:15:22Z",  "instance_id": "string",  "issuer": "string",  "limits_url": "string",  "name": "string",  "object": "string",  "project_id": "string",  "region": "us",  "secret_key": "string",  "secret_key_id": "string",  "tenancy_mode": "b2b"}
GET
/unclaimed-instances/{instance_id}

Read an unclaimed instance: with its claim token in X-Pontive-Claim-Token, its status for polling (720 reads per instance per hour); or with a Pontive user's session and a claim link's code in X-Pontive-Claim-Code, for the dashboard's claim page, with the caller's workspaces where they may create a project, each with whether the instance fits (eligible, or reason: project_limit_exceeded, workspace_suspended, workspace_paused, workspace_cancelled) and what the claim would start there (charges, as a project create answers them); 20 session reads and claims per user per hour. Reading does not use up the code. Once claimed, the claim token keeps reading status claimed with claimed_at and nothing else of the instance. 404 unclaimed_instance_not_found for an unknown or expired instance or a wrong token, alike; 404 claim_link_invalid for an unknown, expired or used code.

Path Parameters

instance_id*string

Instance ID

Header Parameters

X-Pontive-Claim-Token?string

The claim token

X-Pontive-Claim-Code?string

A claim link's code, with a Pontive user's session

Response Body

OK

application/json
  1. response
claimed_at?string

Null until claimed.

Formatdate-time
created_at?string
Formatdate-time
expires_at?string
Formatdate-time
instance_id?string
issuer?string
name?string
object?string
project_id?string
region?string
Value in"us""eu""au"
status?string
Value in"unclaimed""claimed"
tenancy_mode?string
Value in"b2b""b2c"
workspaces?array<>

With a Pontive user's session and a link's code: the caller's workspaces where they may create a project, each with whether the instance fits and what a claim would start charging there.

Example Request
curl -X GET 'https://api.pontive.com/v1/unclaimed-instances/string'
Example Response
{  "claimed_at": "2019-08-24T14:15:22Z",  "created_at": "2019-08-24T14:15:22Z",  "expires_at": "2019-08-24T14:15:22Z",  "instance_id": "string",  "issuer": "string",  "name": "string",  "object": "string",  "project_id": "string",  "region": "us",  "status": "unclaimed",  "tenancy_mode": "b2b",  "workspaces": [    {      "charges": {        "included": true      },      "eligible": true,      "name": "string",      "plan": "string",      "reason": "string",      "workspace_id": "string"    }  ]}
POST
/unclaimed-instances/{instance_id}/claim

Claim an unclaimed instance into one of the caller's workspaces, with a Pontive user's session and a claim link's code in X-Pontive-Claim-Code: its project moves into the workspace intact (ids, issuer, users, apps, keys and settings unchanged), its expiry is cleared and every claim link of it dies. Needs project:create on the workspace, as a project create does (403 otherwise). name renames the project. Answers the project, now in the workspace, with what it started charging. 404 claim_link_invalid for an unknown, expired or used code; 409 instance_claimed; 409 project_limit_exceeded when the workspace's plan holds no more projects; 403 workspace_suspended, workspace_paused or workspace_cancelled. With X-Idempotency-Key, the answer is kept for 24 hours: a retry with the same key and body is answered it again without claiming, and the same key with another body is 422 idempotency_key_reused. 20 session reads and claims per user per hour.

Path Parameters

instance_id*string

Instance ID

Header Parameters

X-Pontive-Claim-Code*string

The claim link's code

X-Idempotency-Key?string

Idempotency key

Request Body

The workspace, and a new name

application/json
  1. body

The workspace, and a new name

name?string

Renames the project; omitted keeps its name.

workspace_id?string

The workspace the project moves into: the caller must be able to create a project there.

Response Body

OK

application/json
  1. response
charges?

What the project started billing per month, on the project a create returns and nowhere else: nothing on Free or in one of the plan's included slots; else the additional-project fee and, on a b2b project, the uplift (pontive-spec 10). Absent where the installation bills nothing.

compliance_tags?

Compliance tags of the project

created_at?string

The time when the project was created

Formatdate-time
deleted_at?string

The time when the project was deleted, if applicable

Formatdate-time
description?string

The description of the project

id?string

The unique identifier of the project

instances?array<>

Read-only summary of the project's instances, oldest first

metadata?

The new metadata for the project

name?string

The name of the project

object?string

The object type

paused_at?string

The time when the project was paused, if applicable

Formatdate-time
purge_scheduled_at?string

When a deleted project's restore window ends, deleted_at plus 30 days: it can be restored until then, and is purged after (route review D30). Null unless the project is deleted.

Formatdate-time
region?string

The region where the project and all its instances are deployed

Value in"us""eu""au"
slug?string

The slug of the project. Client-supplied, permanent, globally unique and never reused.

status?string

The current status of the project

Value in"active""paused""deleted"
tenancy_mode?string

The project's tenancy mode, chosen at creation and immutable. Every instance inherits it.

Value in"b2b""b2c"
updated_at?string

The time when the project was last updated

Formatdate-time
workspace_id?string

The ID of the workspace that owns this project

Example Request
curl -X POST 'https://api.pontive.com/v1/unclaimed-instances/string/claim' \  -H 'X-Pontive-Claim-Code: string' \  -H 'Content-Type: application/json' \  -d '{}'
Example Response
{  "charges": {    "included": true  },  "compliance_tags": {    "GDPR": true,    "HIPAA": true  },  "created_at": "2019-08-24T14:15:22Z",  "deleted_at": "2019-08-24T14:15:22Z",  "description": "string",  "id": "string",  "instances": [    {      "environment": "production",      "id": "string",      "name": "string",      "slug": "string",      "status": "active"    }  ],  "metadata": {    "property1": "string",    "property2": "string"  },  "name": "string",  "object": "string",  "paused_at": "2019-08-24T14:15:22Z",  "purge_scheduled_at": "2019-08-24T14:15:22Z",  "region": "us",  "slug": "string",  "status": "active",  "tenancy_mode": "b2b",  "updated_at": "2019-08-24T14:15:22Z",  "workspace_id": "string"}
POST
/unclaimed-instances/{instance_id}/claim-links

Mint a claim link with the claim token in X-Pontive-Claim-Token: https://app.pontive.com/claim/{instance_id}#code={code}, the code in the fragment, single use, valid for one hour. Give the person the link, never the token. Minting does not end older links; the first one used ends every other. 30 per instance and 60 per IP address per hour. 404 unclaimed_instance_not_found for an unknown or expired instance or a wrong token; 409 instance_claimed once claimed.

Path Parameters

instance_id*string

Instance ID

Header Parameters

X-Pontive-Claim-Token*string

The claim token

Response Body

Created

application/json
  1. response
expires_at?string
Formatdate-time
object?string
url?string

The dashboard's claim page, the code in the fragment.

Example Request
curl -X POST 'https://api.pontive.com/v1/unclaimed-instances/string/claim-links' \  -H 'X-Pontive-Claim-Token: string'
Example Response
{  "expires_at": "2019-08-24T14:15:22Z",  "object": "string",  "url": "string"}