Getting Started
Make your first RoofAngle API call in about five minutes.
1. Get your credentials
Create a sandbox account, confirm the 6 digit code we email you, and you get a Client ID (ra_client_...) and Client Secret. Everything below runs against the sandbox.
Ready for production credentials? Email support@roofangle.com.
Keep your secret safe
The client secret is shown once and cannot be recovered. Store it in a secrets manager, never in source code or a browser app.
2. Choose an API version
| v4 | v1 | |
|---|---|---|
| Who collects payment | You do, if you charge your customer at all | RoofAngle, through Stripe Checkout |
| Order creation | Placed immediately | Customer pays first via checkoutUrl |
| How you settle | Invoiced on your billing cycle | Per order, at purchase time |
| Everything else | Identical | Identical |
Pick by how you want to settle. Choose v1 to hand payment off to RoofAngle and place orders straight from your own site. Choose v4 to place orders immediately and be invoiced on a cycle.
3. Get a token
bash
curl -X POST https://sandboxclient-api.roofangle.com/v4/auth/token \
-H "Content-Type: application/json" \
-d '{"clientId": "ra_client_XXXX", "clientSecret": "YOUR_SECRET"}'json
{ "accessToken": "eyJhbGciOi...", "expiresIn": 3600, "tokenType": "Bearer" }4. List your services
bash
curl https://sandboxclient-api.roofangle.com/v4/services \
-H "Authorization: Bearer eyJhbGciOi..."The response contains the serviceId values (with your tenant's pricing) that you'll use to create orders.
5. Create your first order
bash
curl -X POST https://sandboxclient-api.roofangle.com/v4/orders \
-H "Authorization: Bearer eyJhbGciOi..." \
-H "Content-Type: application/json" \
-d '{
"customerName": "John Smith",
"customerEmail": "john.smith@example.com",
"address": "123 Main Street, Austin, TX 78701",
"propertyType": "Residential",
"serviceId": "SERVICE_ID_FROM_STEP_4",
"rushOrder": false,
"pdfRequired": true
}'6. Get the deliverables
When the report is ready you'll receive an order.delivered webhook with a 24-hour downloadAllUrl, or list and download files yourself via the Files API.
