Get invite summary
/api/v1/identity-invites/summaryAuthentication
- Bearer Token
AuthorizationJWT access token
- API Key
X-API-KeyAPI key for management-tier access
Code samples
curl -X GET "https://api.canopy.dev/api/v1/identity-invites/summary" \ -H "X-API-Key: $CANOPY_API_KEY"
const response = await fetch("https://api.canopy.dev/api/v1/identity-invites/summary", {
method: "GET",
headers: {
"X-API-Key": "$CANOPY_API_KEY"
},
});
const data = await response.json();import requests
response = requests.get(
"https://api.canopy.dev/api/v1/identity-invites/summary",
headers={
"X-API-Key": "$CANOPY_API_KEY"
},
)
data = response.json()package main
import (
"net/http"
)
func main() {
req, _ := http.NewRequest("GET", "https://api.canopy.dev/api/v1/identity-invites/summary", nil)
req.Header.Set("X-API-Key", "$CANOPY_API_KEY")
resp, _ := http.DefaultClient.Do(req)
defer resp.Body.Close()
}Responses
200 Invite status counts returned
{
"total_invites": 0,
"pending_count": 0,
"pending_with_role_count": 0,
"accepted_count": 0,
"expired_count": 0,
"revoked_count": 0
}application/json
total_invites *numberpending_count *numberpending_with_role_count *numberSubset of `pending_count` whose invites carry a role_id (invite-and-assign flow). Drives the dashboard's 'Assign Role to Identity' onboarding-step pending state — once an invite-with-role is accepted, the backend auto-creates the assignment, so we can show the assignment step as pending in the meantime.
accepted_count *numberexpired_count *numberrevoked_count *number
401 Invalid or expired token
403 This token is not authorized for this endpoint (wrong principal type — e.g., admin token on identity-only endpoint, or vice versa)