API request logs

API request logs let you inspect recent public API traffic made with the current API key. Use them to debug auth failures, repeated retries, unexpected 4xx/5xx responses, which resource a request targeted, and whether a sandbox-bound test key is hitting the expected sandbox routes.

This surface is intentionally scoped to the calling key (it is not a merchant-wide audit log across every key). The list returns request summaries only: method, route, status, latency, resource, and error code. The detail endpoint adds redacted headers and, for eligible write requests, redacted request and response bodies, plus a ready-to-run reproduction; credentials, card data, and personal data are always replaced with [REDACTED] before storage. Listing requires the developer.request_logs.self.read scope and detail requires developer.request_logs.self.detail.read.

The Debugging guide walks through the full workflow, from a request_id to a diagnosis to a resource timeline. Pair it with the Error handling guide to map error codes to fixes, and the Testing guide for the sandbox testing loop.

Get the current API key authentication context#

GET/v1/developer/auth-contextRequires an API key or a bearer token

Returns non-secret metadata for the authenticated API key, including its merchant, environment, sandbox binding, and granted scopes. A valid API key is required, but no additional API scope is required.

Response · 200
dataobjectrequired
metaobject
request_idstring

Error codes

AUTH_REQUIREDINVALID_API_KEYRATE_LIMIT_EXCEEDEDSERVICE_UNAVAILABLE
Bash
curl https://api.withflintpay.com/v1/developer/auth-context \
  -H "Authorization: Bearer YOUR_API_KEY"
JSON
{
  "data": {
    "api_key_id": "key_123",
    "auth_type": "api_key",
    "environment": "sandbox",
    "expires_at": null,
    "merchant_id": "mer_123",
    "name": "local-dev",
    "organization_id": "org_123",
    "sandbox_id": "test_123",
    "scopes": [
      "payments.payment_intents.read"
    ]
  },
  "request_id": "bce56cba-0827-44aa-bb56-4f200ba15ee6"
}

Get API request log detail for the current API key#

GET/v1/developer/request-logs/{api_request_log_id}Requires scope: developer.request_logs.self.detail.read

Returns redacted request log detail for a request generated by the authenticated API key. Detail responses remain current-key scoped and redact headers, query parameters, request bodies, and response bodies before returning them.

Path parameters
api_request_log_idstringrequired

Flint API request log ID.

Response · 200
dataobjectrequired
metaobject
request_idstring

Error codes

AUTH_REQUIREDINSUFFICIENT_SCOPEINVALID_API_KEYINVALID_REQUESTRATE_LIMIT_EXCEEDEDRESOURCE_NOT_FOUND
Bash
curl https://api.withflintpay.com/v1/developer/request-logs/rlog_123 \
  -H "Authorization: Bearer YOUR_API_KEY"
JSON
{
  "data": {
    "api_request_log_id": "rlog_123",
    "request_id": "bce56cba-0827-44aa-bb56-4f200ba15ee6",
    "correlation_id": "rlog_123",
    "http_method": "POST",
    "path": "/v1/payment-intents",
    "query_params": null,
    "route_pattern": "POST /v1/payment-intents",
    "status_code": 400,
    "latency_milliseconds": 42,
    "request_headers": {
      "content-type": "application/json"
    },
    "request_body": {
      "amount": 2500,
      "currency": "USD",
      "payment_source_token": "[REDACTED]"
    },
    "response_body": {
      "error": {
        "code": "VALIDATION_ERROR",
        "message": "payment_source_token is invalid."
      }
    },
    "response_content_type": "application/json",
    "resource_type": "payment_intent",
    "resource_id": "pi_123",
    "error_code": "VALIDATION_ERROR",
    "error_category": "validation",
    "error_summary": "The request payload or query parameters did not pass validation.",
    "retryable": false,
    "recommended_action": "Fix the field identified by the error response, then retry with the same idempotency key if this was the same logical operation.",
    "created_at": "2026-03-17T14:30:00Z",
    "reproduction": {
      "http_method": "POST",
      "path": "/v1/payment-intents",
      "query_params": null,
      "headers": {
        "Authorization": "Bearer <API_KEY>",
        "Idempotency-Key": "<NEW_IDEMPOTENCY_KEY>"
      },
      "body": {
        "amount": 2500,
        "currency": "USD",
        "payment_source_token": "[REDACTED]"
      },
      "curl": "curl -X POST https://api.withflintpay.com/v1/payment-intents -H \"Authorization: Bearer <API_KEY>\" -H \"Idempotency-Key: <NEW_IDEMPOTENCY_KEY>\" --data '<REDACTED_OR_CAPTURED_BODY>'",
      "safe_to_reproduce": false,
      "reproduction_complete": false,
      "redactions_present": true,
      "recommended_environment": "test",
      "warnings": [
        "This request may mutate live data; reproduce in test mode unless you have verified it is safe."
      ]
    }
  },
  "request_id": "bce56cba-0827-44aa-bb56-4f200ba15ee6"
}

Get a resource timeline#

GET/v1/developer/resource-timelines/{resource_id}Requires scope: developer.resource_timelines.read

Returns summary-only API request, webhook event, and webhook delivery attempt entries for a single public API resource. The caller must have developer.resource_timelines.read and the matching read scope for the requested resource type.

Path parameters
resource_idstringrequired

Flint public API resource ID.

Query parameters
resource_typestring

Optional resource type. Must match the resource_id prefix when present.

includearray of enum

Optional comma-separated timeline entry groups. Defaults to requests,webhooks,attempts.

requestswebhooksattempts
page_sizeinteger

Page size, default 20, max 100.

page_tokenstring

Cursor returned by the previous timeline response.

occurred_afterstring

RFC3339 lower bound for occurred_at.

occurred_beforestring

RFC3339 upper bound for occurred_at.

Response · 200
dataobjectrequired
metaobject
next_page_tokenstring
request_idstring

Error codes

AUTH_REQUIREDINSUFFICIENT_SCOPEINVALID_API_KEYINVALID_REQUESTRATE_LIMIT_EXCEEDEDRESOURCE_NOT_FOUND
Bash
curl https://api.withflintpay.com/v1/developer/resource-timelines/ord_123 \
  -H "Authorization: Bearer YOUR_API_KEY"
JSON
{
  "data": {
    "resource_id": "pi_123",
    "resource_type": "payment_intent",
    "test": true,
    "entries": [
      {
        "entry_type": "api_request",
        "resource_timeline_entry_id": "rlog_123",
        "occurred_at": "2026-03-17T14:30:00Z",
        "test": true,
        "resource_type": "payment_intent",
        "resource_id": "pi_123",
        "api_request_log_id": "rlog_123",
        "correlation_id": "rlog_123",
        "request_id": "bce56cba-0827-44aa-bb56-4f200ba15ee6",
        "http_method": "POST",
        "path": "/v1/payment-intents/pi_123/confirm",
        "route_pattern": "POST /v1/payment-intents/{payment_intent_id}/confirm",
        "status_code": 200,
        "latency_milliseconds": 42
      },
      {
        "entry_type": "webhook_event",
        "resource_timeline_entry_id": "whev_123",
        "occurred_at": "2026-03-17T14:30:01Z",
        "test": true,
        "resource_type": "payment_intent",
        "resource_id": "pi_123",
        "api_request_log_id": "rlog_123",
        "correlation_id": "rlog_123",
        "request_id": "bce56cba-0827-44aa-bb56-4f200ba15ee6",
        "status": "delivered",
        "webhook_event_id": "whev_123",
        "webhook_endpoint_id": "whep_123",
        "event_type": "payment_intent.succeeded",
        "event_source": "business_event",
        "automatic_attempt_count": 1,
        "max_attempts": 9
      },
      {
        "entry_type": "webhook_delivery_attempt",
        "resource_timeline_entry_id": "watt_123",
        "occurred_at": "2026-03-17T14:30:02Z",
        "test": true,
        "resource_type": "payment_intent",
        "resource_id": "pi_123",
        "api_request_log_id": "rlog_123",
        "correlation_id": "rlog_123",
        "request_id": "bce56cba-0827-44aa-bb56-4f200ba15ee6",
        "status": "delivered",
        "status_code": 200,
        "webhook_event_id": "whev_123",
        "webhook_delivery_attempt_id": "watt_123",
        "delivery_trigger": "automatic_delivery",
        "attempt_number": 1,
        "duration_milliseconds": 98
      }
    ]
  },
  "next_page_token": "Zm9yd2FyZC1vbmx5LW9wYXF1ZS1jdXJzb3I",
  "request_id": "bce56cba-0827-44aa-bb56-4f200ba15ee6"
}
Rate this doc