Purpose
GET
/dms/scan-invitesScan recent DM messages for Discord invite links.
Returns a list of found invite codes/URLs.
- limit: Messages per channel to scan
- after: Only scan messages after this message ID (for incremental scanning)
Authentication
Send a tenant API key as Authorization: Bearer <key> or X-API-Key: <key>. Keep keys server-side and use the account slug for the connected Discord account.
Parameters
NameInRequiredType / constraints
limit
query
optional
integer · default 50 · range 1–100
after
query
optional
integer · default null
Request example
Replace the tenant, account, and resource placeholders before running this read-only request.
curl --fail-with-body \
-H "Authorization: Bearer ${DATAZ_API_KEY}" \
"https://dataz.md/gateway/v1/{tenant_slug}/accounts/{account_slug}/dms/scan-invites?limit=100"
Response schema
Documented responses
200Response model: JSON responseobject
Response example
Representative JSON shape. The live response can include additional documented fields.
{
"invites": [],
"count": 0
}
Errors
Common responses
401Missing or invalid tenant API key.authentication
403The tenant, account, or connected provider cannot access the requested resource.authorization
404The route or requested provider resource was not found.not found
422A path or query parameter is invalid.validation
429Rate limited; wait for the Retry-After interval before retrying.rate limit
Limits and pagination
- Use
limitto bound each response; it defaults to 50 and accepts 1–100. - Use
beforeto continue toward older records orafterfor incremental reads; store source IDs as cursors. - Provider or demo limits can return HTTP 429. Wait for the
Retry-Afterinterval before retrying.
Related tutorials
Read-only notes
This reference page documents a public GET endpoint. Setup/token, AI, dev, internal, and mutating routes are excluded from static reference generation.