Links › Move several links to the trash

Links

Move several links to the trash

DELETE/api/{ORG}/linksPermalink

Answers the BulkResult.

Permission
Links · delete
Plan
Plans that include the API: Pricing
Retry
Safe with an Idempotency-Key

Example request

bash
curl -X DELETE "https://console.brevily.com/api/NORTHWIND/links?id=01JC6Y8QH2M4ZK7T9VRW3XNB5D" \  -H "x-api-key: brv_ak_7Fq2Lw9xK3" \  -H "x-api-secret: $BREVILY_SECRET" \  -H "Idempotency-Key: 4f9c1e2a-autumn"

Example answer

json
{  "done": 1,  "skipped": 0,  "more": false}

Made-up values. Send your own Idempotency-Key, one per change.

Path parameters
NameTypeRequiredDescriptionAllowed values
ORGstringrequiredYour organisation’s code.3 to 20 characters
Query parameters
NameTypeRequiredDescriptionAllowed values
idstring[]requiredA link to move to the trash; repeat it for up to 100 (?id=A&id=B).—

BulkResult

Answer fields
NameTypeDescriptionAllowed values
doneintegerLinks changed.—
skippedintegerLinks that could not change that way, or already had.—
morebooleanSelect all matched more than one run takes: run it again for the rest.—
Errors
Status Code When
400 VALIDATION_FAILED A field, a parameter or the body is wrong; details.fields says which.
400 IDEMPOTENCY_KEY_INVALID The Idempotency-Key is longer than 255 characters.
401 UNAUTHENTICATED No key, a key that does not match, or one expired or revoked.
403 ACCESS_DENIED The key lacks Links · delete, or the organisation’s plan does not include it.
404 NOT_FOUND No organisation with that code for this key, or no such record in it.
409 CONFLICT
409 IDEMPOTENCY_IN_FLIGHT The first call with this Idempotency-Key is still running.
413 PAYLOAD_TOO_LARGE
415 UNSUPPORTED_MEDIA
422 IDEMPOTENCY_MISMATCH The same Idempotency-Key was sent with a different request.
429 RATE_LIMITED Too many calls: wait Retry-After seconds.

Counted with every other call of the organisation, by plan: Pricing. The answer carries RateLimit-Limit, RateLimit-Remaining and RateLimit-Reset; more on rate limits.