Skip to content
Last updated

Follow this guide to make your first Shippo API call. In this guide, you will learn how to create an address using the Shippo API.

Generate your API Token

Follow the Authentication guide to generate your API Token.

Note

When learning about and testing the Shippo API, we recommend using the test token. Using your test token means all the calls you make to the Shippo API are free.

Install the client library for your language

# No library needed for cURL

See our client libraries page for more details.

Make your first API call

To make sure everything is working, make a simple call to create a new address in your Shippo account.

You must replace <API_TOKEN> with the token you copied from Step 1.

curl https://api.goshippo.com/addresses/ \
   -H "Authorization: ShippoToken <API_TOKEN>" \
   -d name="Shawn Ippotle" \
   -d company="Shippo" \
   -d street1="215 Clayton St." \
   -d street2="" \
   -d city="San Francisco" \
   -d state="CA" \
   -d zip=94117 \
   -d country="US" \
   -d phone="+1 555 341 9393" \
   -d email="shippotle@shippo.com"\
   -d is_residential=True\
   -d metadata="Customer ID 123456"

If your request to create a new address was a success, the response should look like the following. If you don't get a response like this, check your code and make sure your API token is correct.

{
   "is_complete": true,
   "object_created":"2022-07-09T02:19:13.174Z",
   "object_updated":"2022-07-09T02:19:13.174Z",
   "object_id":"d799c2679e644279b59fe661ac8fa488",
   "object_owner":"shippotle@shippo.com",
   "validation_results": {},
   "name":"Shawn Ippotle",
   "company":"Shippo",
   "street_no": "",
   "street1":"215 Clayton St.",
   "street2":"",
   "street3":"",
   "city":"San Francisco",
   "state":"CA",
   "zip":"94117",
   "country":"US",
   "longitude": null,
   "latitude": null,
   "phone":"15553419393",
   "email":"shippotle@shippo.com",
   "is_residential":true,
   "metadata":"Customer ID 123456"
}

Next steps

You now know how to make API calls using the Shippo API. Your next step is to create your first shipping label.

You can also start exploring our API reference to learn about all the Shippo API features.