Get an archive publish receipt - Spacefast Docs

Get an archive publish receipt

Returns the publish receipt for a build that POST /v1/publish created from an archive, in the shape that call already answered with. Poll it while the build runs: the version and activation blocks appear once the build produces a version. A build created any other way is not found here.

GET /v1/builds/{buildId}/receipt

Authorization

Authorization Bearer token · header required

Authorization: Bearer <token>

Path parameters

Responses

200 Response for status 200

{
  "$schema": "string<uri>",
  "data": {
    "space": {
      "id": "string",
      "slug": "string",
      "title": "string",
      "publicName": "string",
      "defaultHostname": "string",
      "liveUrl": "string"
    },
    "build": {
      "id": "string",
      "spaceId": "string",
      "status": "waiting_for_source",
      "input": {
        "kind": "archive"
      },
      "source": null,
      "settingsSnapshot": {
        "rootDirectory": null,
        "installDirectory": null,
        "installCommand": null,
        "buildCommand": null,
        "outputDirectory": null,
        "ignoredBuildCommand": null,
        "frameworkPreset": null,
        "platformPreset": null,
        "allowUnsupportedPlatformFeatures": false,
        "timeoutSeconds": 900
      },
      "target": {
        "channel": null,
        "preview": false
      },
      "retryOfBuildId": null,
      "producedVersionId": "string",
      "reusedVersionId": null,
      "diagnostics": [],
      "createdAt": "2019-08-24T14:15:22Z",
      "startedAt": "2019-08-24T14:15:22Z",
      "finishedAt": "2019-08-24T14:15:22Z"
    },
    "version": {
      "id": "string",
      "status": "building",
      "immutableUrl": "string",
      "ref": "string",
      "number": 9007199254740991,
      "manifestHash": "string"
    },
    "activation": {
      "channel": "live",
      "outcome": "activated",
      "currentLiveVersionId": "string",
      "reason": "channel_promotion_manual"
    },
    "next": {
      "action": "done",
      "url": "string",
      "retryAfter": 9007199254740991,
      "hint": "string"
    },
    "git": {
      "managedBy": "spacefast",
      "remoteUrl": "string",
      "repository": "string",
      "defaultBranch": "string"
    },
    "access": {
      "url": "http://example.com",
      "token": "stringstringstri",
      "expiresAt": "2019-08-24T14:15:22Z"
    },
    "claim": {
      "key": "string",
      "url": "http://example.com",
      "claimUrl": "http://example.com",
      "expiresAt": "2019-08-24T14:15:22Z"
    },
    "diagnostics": [
      {
        "code": "string",
        "severity": "info",
        "message": "string",
        "path": "string",
        "provider": "infra",
        "details": {
          "property1": null,
          "property2": null
        },
        "fix": "string",
        "retryable": true
      }
    ],
    "links": {
      "inspect": "string",
      "build": "string",
      "status": "string",
      "version": "string"
    }
  }
}

Try it

Server

Base URL: https://api.spacefast.com

Parameters

Request examples

cURL

curl -X GET "https://api.spacefast.com/v1/builds/string/receipt" \
  -H "Authorization: Bearer YOUR_TOKEN"

JavaScript

const response = await fetch("https://api.spacefast.com/v1/builds/string/receipt", {
  method: "GET",
  headers: {
    "Authorization": "Bearer YOUR_TOKEN"
  }
});

Python

import requests

response = requests.get(
    "https://api.spacefast.com/v1/builds/string/receipt",
    headers={
        "Authorization": "Bearer YOUR_TOKEN"
    },
)