Version Sub-Resource Routes

VERSION SUB-RESOURCE ROUTES
GET /version/:versionId/sections // Get sections for a version
GET /version/:versionId/blocks // Get blocks for a version
GET /version/:versionId/assets // Get assets for a version
GET /version/:versionId/citations // Get citations for a version

This is the generic response schema that wraps the data retrieved by any of those endpoints:

RESPONSE
 {
    "public_id":"1642632597.v1",
    "open_access":true,
    "normalized":true,
    "updated_at":"2025-01-15T10:30:00.000Z",
    "data":{ 
    // At least one of the following will be included
    // in here depending on the specific request
       "metadata":[...],
       "sections":[...],
       "blocks":[...],
       "assets":[...],
       "citations":[...]
    }
 }

Schema fields

  • public_id: Version identifier

  • open_access: Whether the version is open access

  • normalized: Whether the version has been processed

  • updated_at: Last update timestamp

  • data.sections: Array of section objects

Get version with expandable fields

Retrieves a version with multiple expandable fields in a single request.

GET https://api.drylab.bio/v1/version/:versionId/expand
curl https://api.drylab.bio/v1/version/1642632597.v1/expand?expand=sections,blocks \
     -H "Authorization: Bearer <YOUR_API_KEY>"

Path parameters

Parameter
Type
Description

versionId

string

Drylab version ID

Query parameters

Parameter
Type
Description

expand

string

Comma-separated fields to expand (sections, blocks, assets, citations, metadata, all)

Response

Identical to the generic response included at the top of the page, with the contents of "data" depending on what the user passes in the expand query parameter.

Get version sections

Retrieves structured sections for a version.

https://api.drylab.bio/v1/version/:versionId/sections
curl https://api.drylab.bio/v1/version/1642632597.v1/sections \
     -H "Authorization: Bearer <YOUR_API_KEY>"

Path parameters

Parameter
Type
Description

versionId

string

Drylab version ID

Response

The sections object is shown here.

SUCCESS (200)
 {
    "public_id":"1642632597.v1",
    "open_access":true,
    "normalized":true,
    "updated_at":"2025-01-15T10:30:00.000Z",
    "data":{
       "sections":[...]
    }
 }

Get version blocks

Retrieves structured content blocks for a version.

https://api.drylab.bio/v1/version/:versionId/blocks
curl https://api.drylab.bio/v1/version/1642632597.v1/blocks \
     -H "Authorization: Bearer <YOUR_API_KEY>"

Path parameters

Parameter
Type
Description

versionId

string

Drylab version ID

Response

The blocks object is shown here.

SUCCESS (200)
 {
    "public_id":"1642632597.v1",
    "open_access":true,
    "normalized":true,
    "updated_at":"2025-01-15T10:30:00.000Z",
    "data":{
       "blocks":[...]
    }
 }

Get version assets

Retrieves downloadable assets for a version.

https://api.drylab.bio/v1/version/:versionId/assets
curl https://api.drylab.bio/v1/version/1642632597.v1/assets \
     -H "Authorization: Bearer <YOUR_API_KEY>"

Path parameters

Parameter
Type
Description

versionId

string

Drylab version ID

Response

The assets object is shown here.

SUCCESS (200)
 {
    "public_id":"1642632597.v1",
    "open_access":true,
    "normalized":true,
    "updated_at":"2025-01-15T10:30:00.000Z",
    "data":{
       "assets":{
          "figures":[...],
          "tables":[...]
       }
    }
 }

Get version citations

Retrieves structured citations for a version.

https://api.drylab.bio/v1/version/:versionId/citations
curl https://api.drylab.bio/v1/version/1642632597.v1/citations \
     -H "Authorization: Bearer <YOUR_API_KEY>"

Path parameters

Parameter
Type
Description

versionId

string

Drylab version ID

Response

The citations object is shown here.

 {
    "public_id":"1642632597.v1",
    "open_access":true,
    "normalized":true,
    "updated_at":"2025-01-15T10:30:00.000Z",
    "data":{
       "citations":[...]
    }
 }

Access requirements

All sub-resource endpoints require:

  • Open access: Version must have open_access: true

  • Normalized: Version must have normalized: true

  • Authentication: Valid API key required

Error responses:

  • 403 Forbidden: Version is not open access

  • 409 Conflict: Version is not normalized yet

  • 404 Not Found: Version or requested content not available

Last updated