---
title: "R2 delivery metadata"
method: GET
path: "/api/v1/r2-credentials"
tags: ["Distribution"]
---

# R2 delivery metadata

`GET /api/v1/r2-credentials`

## Request

- Base URL: `https://propraven.com`
- URL: `https://propraven.com/api/v1/r2-credentials`
- Auth: API key in cookie `sb-<project-ref>-auth-token`

Returns the R2 bucket, the prefixes a credential may name, the credential TTL limits in seconds, the catalog object and whether the caller's plan carries R2 delivery. AUTHENTICATED (signed-in session only): an anonymous call gets HTTP 401 from the session gate and an API key is not accepted. Credentials themselves are minted with POST on the same path from a signed-in session (see https://propraven.com/docs/r2); that operation is not part of the API-key contract.

## Response `200`

R2 delivery metadata.

- object
  - `bucket` string, required
  - `endpoint_template` string, required
  - `region` string, required
  - `available_prefixes` string[], required
  - `max_ttl_seconds` integer, required
  - `default_ttl_seconds` integer, required
  - `docs` string, required
  - `catalog` object, required
    - `uri` string, required
    - `prefix` string, required
  - `entitled` boolean, nullable, required: Whether the caller's plan carries R2 delivery; null when the plan lookup failed.
  - `upgrade_url` string, required

## Other responses

- `401`: Missing, malformed or invalid credential.
- `405`: The endpoint exists but does not support this method. `Allow` lists the methods it does.
- `500`: Unexpected server error. The body never carries database or driver text.

---

[API](https://skmtc.dev/propraven/apis/propraven-api.md) · [All operations](https://skmtc.dev/propraven/apis/propraven-api/llms.txt) · [OpenAPI document](https://skmtc.dev/propraven/apis/propraven-api/revisions/37f8158c4eda?raw)
