Centralized build numbers for your apps and libraries.

Success!
Error!

$ curl -X POST https://api.buildnumber.dev/builds \
    --user API_TOKEN:

 

{“buildNumber": 42}

What is this?

buildnumber.dev centralizes all your build numbers so they're kept in sync.

For instance, if you use Travis to build your iOS app but also build from your own computer, you’ll need to make sure Travis doesn't use the same build number than your computer's. You'll also need to make sure each build number is unique and incremental.

This is where buildnumber.dev is helpful: by centralizing all your build numbers into one single database, we can give you a new, unique, and sequential build number to use in your next build.

Examples

Create a new build

This will create a new build for the com.example.myapp package. If you never created a build for this package before, the initial build number will be 1.

$ curl -X POST https://api.buildnumber.dev/builds \
    --user API_TOKEN:
    {"buildNumber": 42}

Create a new build and return its build number in plain text

This is useful for bash scripts, since you can just store the request output in a variable.

$ curl -X POST https://api.buildnumber.dev/builds?output=buildNumber \
    --user API_TOKEN:
    43

Create a new build with additional information

You can pass a JSON-encoded meta data dictionary for your build. You can retrieve this data later when querying a specific build.

$ curl -X POST https://api.buildnumber.dev/builds \
    --header 'Content-Type: application/json' \
    --data '{"head": "60b7eca"}' \
    --user API_TOKEN:
    {"buildNumber": 44, "head": "60b7eca"}

Get the last build

$ curl https://api.buildnumber.dev/builds/last \
    --user API_TOKEN:
    {"buildNumber": 44, "head": "60b7eca"}

Get a specific build by its build number

$ curl https://api.buildnumber.dev/builds/43 \
    --user API_TOKEN:
    {"buildNumber": 43, "head": "43b8ecf"}