Releases Index
Materialize a GitHub source
View .md

On-demand GitHub source materialization

POST
/lookups

Resolves a GitHub org/repo coordinate to a registry source. Idempotent — if the source already exists, returns it with status: "existing"; otherwise probes GitHub, inserts a hidden on_demand source row (and a new on_demand org when no curated org claims the segment), and ingests up to 100 releases.

Negative results (not_found, empty) are cached in KV (24h and 6h respectively) so repeat probes don't re-hit GitHub. deferred outcomes (rate-limit, 5xx) are not cached and let the next cron pass retry.

Body requires provider: "github" — other providers are explicitly rejected, not silently accepted. Coordinate must match {org}/{repo} (case-insensitive; URLs are deduped via LOWER(sources.url)).

Authorization

bearerAuth
headerAuthorizationBearer <relk_… | relu_… | OAuth JWT>

Machine/operator tokens use the relk_ prefix; self-serve read-only user keys use relu_; Sign in with Releases supplies an OAuth access token. Required scope depends on the endpoint.

Request Body

application/json
  1. body
provider*string
coordinate*string
Match^[^/\s]+\/[^/\s]+$

Response Body

Lookup result. Inspect status to disambiguate outcomes.

application/json
  1. response
status*string
Value in"indexed""existing""empty""not_found""deferred"
source?
releases?array<>
relatedOrg*|null
Example Request
curl -X POST 'https://api.releases.sh/v1/lookups' \  -H 'Content-Type: application/json' \  -d '{  "provider": "github",  "coordinate": "string"}'
Example Response
{  "status": "indexed",  "source": {    "id": "string",    "slug": "string",    "name": "string",    "type": "string",    "url": "string",    "orgId": "string",    "productId": "string",    "isHidden": true,    "discovery": "curated",    "metadata": "string",    "stars": 0,    "starsFetchedAt": "string",    "createdAt": "string",    "property1": null,    "property2": null  },  "releases": [    {      "id": "string",      "sourceId": "string",      "version": "string",      "title": "string",      "url": "string",      "publishedAt": "string",      "property1": null,      "property2": null    }  ],  "relatedOrg": {    "org": {      "id": "string",      "slug": "string",      "name": "string"    },    "sources": [      {        "id": "string",        "slug": "string",        "name": "string",        "url": "string"      }    ]  }}