Developers
Authentication
Every request carries an API key of your agency in the Authorization header. A key acts on behalf of the agency, not of a person, and sees all the agency's homes.
API keys
Keys look like ie_live_ followed by 40 letters and digits. Send them as a bearer token:
curl https://api.instaenv.com/api/public/v1/organization \
-H "Authorization: Bearer $INSTAENV_API_KEY"- Only the agency's owner and managers can create, see and revoke keys, in Settings → Developers.
- The full key is shown once, when you create it. Instaenv stores only a hash, so a lost key cannot be recovered: create a new one.
- The list shows each key's name, its first characters (
ie_live_xxxxxxxx…), scopes, who created it, when it was last used and when it expires. - A missing, unknown, expired or revoked key gets
401with the codeunauthenticated.
Scopes
A key can only do what its scopes allow. Give each integration the fewest it needs.
| Scope | Allows |
|---|---|
properties:read | List and read homes, their page, texts, photos and 3D tour if they have one. |
properties:write | Create, update and delete homes, and publish or unpublish them. |
leads:read | List leads, for the agency or for one home. |
webhooks:manage | Manage webhook endpoints through the API (optional; the Settings screen does the same). |
GET /organization and GET /webhook-events work with any scope. The presets in Settings are Read only (properties:read, leads:read) and Read and write (adds properties:write); Custom lets you tick scopes one by one.
A call outside the key's scopes gets 403 and names the scope it needed:
{
"error": {
"code": "insufficient_scope",
"message": "This key lacks the properties:write scope.",
"required": "properties:write"
}
}Expiry
A key can expire on a date you choose when you create it, or never. After that date it gets 401 like a revoked key.
Rotation and revocation
Keys are not edited in place. To rotate one:
- Create a new key with the same scopes.
- Deploy it to your integration.
- Check in Settings that the old key's “last used” stops moving.
- Revoke the old key.
Revoking takes effect immediately and cannot be undone: every request with that key gets 401 from then on.
Keeping keys secret
- Call the API from your server only. A key in a browser, a mobile app or a public repository can be read by anyone.
- Keep keys in environment variables or a secrets manager, never in your source code or logs.
- Use one key per integration, so you can revoke one without stopping the others.
- If a key leaks, revoke it in Settings straight away and create a new one.
A key sees every home and lead of the agency, including contact details of people who asked about a home. Treat it like a password.