---
title: "GET /api/grants/{id}"
method: GET
path: "/api/grants/{id}"
tags: ["grants"]
---

# GET /api/grants/{id}

`GET /api/grants/{id}`

## Request

- The document declares no server URL.
- Auth: one of:
  - API key in header `Authorization`
  - API key in cookie `sessionid`

Airtime grants: a window of airtime given to one organization, and the
list of what plays in it.

Members see their organizations' grants and replace a grant's list
while it is open (or until air, if it is exempt from locking). Staff
see every grant, create grants, and cancel or exempt them.

## Path parameters

- `id` integer, required

## Response `200`

- AirtimeGrant
  - `id` integer, required
  - `organization` GrantOrganization, required
    - `id` integer, required
    - `name` string, required
  - `starttime` string, date-time, required
  - `endtime` string, date-time, required
  - `state` 'open' | 'locked' | 'compiled' | 'cancelled', required: * `open` - Open * `locked` - Locked * `compiled` - Compiled * `cancelled` - Cancelled
  - `locksAt` string, date-time, required
  - `lockExempt` boolean, required: Editable until air; every save after compiling recompiles it. Staff only.
  - `recipe` Recipe, nullable, required: How the grant fills the time its pinned items leave. Null: hand-made.
    - `id` integer, required
    - `kind` 'uploads' | 'series' | 'playlist' | 'jukebox', required: * `uploads` - Everything the owner uploads * `series` - One of the owner's series * `playlist` - A list of videos * `jukebox` - The video jukebox
    - `description` string, required
    - `series` integer, nullable
    - `seriesName` string, nullable, required
    - `name` string
    - `categories` integer[]
    - `shortest` string, nullable
    - `longest` string, nullable
    - `newerThanDays` integer, nullable
    - `olderThanDays` integer, nullable
  - `originSlot` integer, nullable, required: Provenance only: the grant copied the slot's time when issued.
  - `items` GrantItem[], required
    - `position` integer, required
    - `video` GrantItemVideo, nullable, required
      - `id` integer, required
      - `name` string, required
      - `duration` string, required
      - `organization` GrantOrganization, required
        - `id` integer, required
        - `name` string, required
      - `pendingUpload` boolean, required: An entry made ahead of its file; its duration was set by hand.
      - `liveSource` GrantItemLiveSource, nullable, required: Set for a live programme: it airs from this source until it has a file.
        - `id` integer, required
        - `name` string, required
    - `poster` GrantItemPoster, nullable, required: Set instead of `video` for a text poster.
      - `id` integer, required
      - `template` 'standard' | 'notice', required: * `standard` - Vanlig * `notice` - Viktig melding
      - `heading` string, required
      - `text` string, required
      - `duration` string, required: How long it is on screen each time it airs.
    - `graphic` GrantItemGraphic, nullable, required: Set instead of `video` for a staff graphic, on for `duration`.
      - `id` integer, required
      - `name` string, required
      - `url` string, required: Where CasparCG loads it from: a full address, or a path on the site such as /infographics/ (add ?page=<id> to hold one page). Playout adds ?duration=<ms>.
    - `duration` string, nullable, required: How long the graphic is on. Only for a graphic.
    - `pinned` boolean, required: Chosen by the owner. Automatic filling keeps it and fills around it.
  - `itemsDuration` string, required: From the grant's start to the end of the list, with the gaps that start each programme on the five-minute grid.
  - `padded` boolean, required: Whether programmes start on the five-minute grid, at least 30 s after the programme before. Posters follow whatever is before them. False for a jukebox grant, which plays back to back.
  - `canEdit` boolean, required: Whether the requesting user may replace the list right now.
  - `startedItems` integer, required: How many entries at the head of the list have aired, are on air or start within seconds. Staff may change what follows them, and move the end, while the grant is on air.
  - `airedItems` integer, required: How many entries at the head of the list have finished airing. An edit must keep them first, as they are. Staff may leave out the ones between this and `startedItems`: that takes them off the air at once.

## Other responses

- `400`
- `401`
- `403`
- `404`
- `405`
- `406`
- `415`
- `500`

## Changes

- **2026-11-16** `deeacd00bbb6`: 2 info
  - added the required property `items/items/duration` to the response with the `200` status
  - added the required property `items/items/graphic` to the response with the `200` status
- **2026-11-16** `d41a12e49411`: 1 info
  - added the required property `airedItems` to the response with the `200` status
- **2026-11-16** `f1620d3cfe01`: 1 info
  - added the required property `startedItems` to the response with the `200` status
- **2026-11-15** `9936784bb7bb`: 1 warning, 2 info
  - added the new `standard` enum value to the `items/items/poster/allOf[#/components/schemas/GrantItemPoster]/template/allOf[#/components/schemas/TemplateEnum]/` response property for the response status `200`
  - removed the `paper` enum value from the `items/items/poster/allOf[#/components/schemas/GrantItemPoster]/template/allOf[#/components/schemas/TemplateEnum]/` response property for the response status `200`
  - removed the `stage` enum value from the `items/items/poster/allOf[#/components/schemas/GrantItemPoster]/template/allOf[#/components/schemas/TemplateEnum]/` response property for the response status `200`
- **2026-11-15** `18f0e5cfab8d`: 1 breaking, 2 info
  - the response property `items/items/video` became nullable for the status `200`
  - added the required property `items/items/poster` to the response with the `200` status
  - added the required property `padded` to the response with the `200` status

[Operation history](https://skmtc.dev/frikanalen/apis/frikanalen-django-api/changes/api/grants/:id/get.md)

---

[API](https://skmtc.dev/frikanalen/apis/frikanalen-django-api.md) - [All operations](https://skmtc.dev/frikanalen/apis/frikanalen-django-api/llms.txt) - [OpenAPI document](https://skmtc.dev/frikanalen/apis/frikanalen-django-api/revisions/ebd4175e41fe?raw)
