API docs / API reference / Portal logins
Approve an access request
POST /v1/portal/requests/{request_id}/approve
Into one of your clients, or a new one (named client_name, else the company); makes the login and emails the invitation.
Path parameters
| request_id required string | — |
Body
| portal_url required https url | — |
| client_id string | — |
| client_name string | — |
| access object | Default: signup_access. |
| product_name string | — |
Send an Idempotency-Key header to make a retry safe: the same key within 24 hours returns the first answer and is never charged twice.
Request
curl -X POST "https://amarkos.com/api/v1/portal/requests/{request_id}/approve" \
-H "Authorization: Bearer $AMARKOS_KEY" \
-H "Content-Type: application/json" \
-d '{
"portal_url": "https://seo.northpeak.io"
}'Response · 200
{
"request": {
"id": "pr_1a2b3c4d5e6f47a8b9c0d1e2f3a4b5c6",
"status": "approved",
"client_id": "cl_8a1b2c3d4e5f40a1b2c3d4e5f6a7b8c9"
},
"user": {
"id": "cu_3c4d5e6f7a8b49c0d1e2f3a4b5c6d7e8",
"email": "ana@birch.example"
},
"invite": {
"sent": true
}
}