Requests
Asking an organisation to let you manage it, and withdrawing a request.
| Method | Path | Summary |
|---|---|---|
| POST | /v1/partner/requests | Ask to manage an organisation |
| POST | /v1/partner/requests/:id/withdraw | Withdraw a request |
#Ask to manage an organisation
POST
/v1/partner/requests- Address
https://<your-org>.brambleit.cloud/api/v1/partner/requests- Requires
- Signed-in session,
X-API-Key, or a Bramble app access token (Authorization: Bearer).
Request body JSON
| Name | Type | Description |
|---|---|---|
domain | string | One of the organisation's verified domains. |
permissions | array of any | What you're asking for: devices.read, device_management.manage. |
note | string | A message for them. |
Response 201
| Field | Type | Description |
|---|---|---|
id | integer | |
customer | string |
Example response
JSON
{
"id": 42,
"customer": "string"
}Errors
| Status | Message |
|---|---|
| 404 | No Bramble organisation uses that domain. |
| 400 | That's your own organisation. |
Example request
Bash
curl -X POST 'https://<your-org>.brambleit.cloud/api/v1/partner/requests' \
-H "X-API-Key: $BRAMBLE_KEY" \
-H "Content-Type: application/json" \
-d '{"domain":"string","permissions":[],"note":"string"}'JavaScript
const res = await fetch('https://<your-org>.brambleit.cloud/api/v1/partner/requests', {
method: 'POST',
headers: { 'X-API-Key': process.env.BRAMBLE_KEY, 'Content-Type': 'application/json' },
body: JSON.stringify({"domain":"string","permissions":[],"note":"string"}),
});
const data = await res.json();Python
import os, requests
r = requests.post(
"https://<your-org>.brambleit.cloud/api/v1/partner/requests",
headers={"X-API-Key": os.environ["BRAMBLE_KEY"]},
json={"domain":"string","permissions":[],"note":"string"},
)
r.raise_for_status()
data = r.json()PowerShell
$headers = @{ 'X-API-Key' = $env:BRAMBLE_KEY }
$body = '{"domain":"string","permissions":[],"note":"string"}'
Invoke-RestMethod -Method POST -Uri 'https://<your-org>.brambleit.cloud/api/v1/partner/requests' -Headers $headers -ContentType 'application/json' -Body $body#Withdraw a request
POST
/v1/partner/requests/:id/withdraw- Address
https://<your-org>.brambleit.cloud/api/v1/partner/requests/:id/withdraw- Requires
- Signed-in session,
X-API-Key, or a Bramble app access token (Authorization: Bearer).
Path parameters
| Name | Type | Description |
|---|---|---|
idrequired | integer |
Response 200
| Field | Type | Description |
|---|---|---|
status | string |
Example response
JSON
{
"status": "active"
}Errors
| Status | Message |
|---|---|
| 404 | Not found |
| 409 | This has already ended. |
Example request
Bash
curl -X POST 'https://<your-org>.brambleit.cloud/api/v1/partner/requests/42/withdraw' \
-H "X-API-Key: $BRAMBLE_KEY"JavaScript
const res = await fetch('https://<your-org>.brambleit.cloud/api/v1/partner/requests/42/withdraw', {
method: 'POST',
headers: { 'X-API-Key': process.env.BRAMBLE_KEY },
});
const data = await res.json();Python
import os, requests
r = requests.post(
"https://<your-org>.brambleit.cloud/api/v1/partner/requests/42/withdraw",
headers={"X-API-Key": os.environ["BRAMBLE_KEY"]},
)
r.raise_for_status()
data = r.json()PowerShell
$headers = @{ 'X-API-Key' = $env:BRAMBLE_KEY }
Invoke-RestMethod -Method POST -Uri 'https://<your-org>.brambleit.cloud/api/v1/partner/requests/42/withdraw' -Headers $headersWas this page helpful?
Thanks for your feedback.