Skip to content

Migrate to build /Status endpoint whenever polling for build status #193

@vincianechen

Description

@vincianechen

The Serverless API now has a new /Status endpoint, which can be used to poll for the build status (instead of getting the same information from the build instance endpoint). You can make a request to .../v1/Services/ZSxxx/Builds/ZBxxx/Status in order to retrieve the build status. The status will still be one of building, completed, or failed. A sample response is:

{
  "status": "completed",
  "url": "https://serverless.twilio.com/v1/Services/ZS55426da69ac03846ec3b1e91686e9c44/Builds/ZB0635857af9586779efb77fe6c613e2d0/Status",
  "account_sid": "AC1d740955285dfa48d491cde240fc58d0",
  "service_sid": "ZS55426da69ac03846ec3b1e91686e9c44",
  "sid": "ZB0635857af9586779efb77fe6c613e2d0"
}

The key in question is still status, but the response should be much faster than using the builds instance endpoint. :)

Metadata

Metadata

Assignees

No one assigned

    Labels

    help wantedExtra attention is needed

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions