> ## Documentation Index
> Fetch the complete documentation index at: https://docs.diskograf.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Get a song

> Full detail for one published song, including every credit, genre and label.



## OpenAPI

````yaml /openapi.json get /v1/songs/{songId}
openapi: 3.1.0
info:
  title: Diskograf API
  description: >-
    A public, read-only REST API over the Diskograf catalogue of Malaysian
    music.


    No authentication is required and no endpoint writes. Requests are rate
    limited

    to 60 per 60 seconds per IP address.


    Every successful response is wrapped in an envelope. List endpoints return

    `{ "data": [...], "meta": { "total", "limit", "offset" } }`; detail
    endpoints

    return `{ "data": {...} }`. Errors return `{ "error": { "code", "message" }
    }`.
  version: 1.0.0
servers:
  - url: https://api.diskograf.com
    description: Production
security: []
tags:
  - name: Songs
    description: The catalogue of published songs and their credits.
  - name: Artists
    description: Performers, writers and producers, and their discographies.
  - name: Genres
    description: The genre taxonomy and the songs in each genre.
  - name: Labels
    description: Record labels and their releases.
  - name: Users
    description: Public contributor profiles. Private account fields are never returned.
  - name: Search
    description: Cross-category keyword search.
  - name: Meta
    description: Service index, statistics and health.
paths:
  /v1/songs/{songId}:
    get:
      tags:
        - Songs
      summary: Get a song
      description: >-
        Full detail for one published song, including every credit, genre and
        label.
      operationId: getV1SongsBySongId
      parameters:
        - name: songId
          in: path
          required: true
          schema:
            type: integer
      responses:
        '200':
          description: The song.
          content:
            application/json:
              schema:
                type: object
                properties:
                  data:
                    type: object
                    properties:
                      id:
                        type: integer
                        minimum: -9007199254740991
                        maximum: 9007199254740991
                      title:
                        type: string
                      slug:
                        type: string
                      released_at:
                        type: string
                      published_at:
                        anyOf:
                          - type: string
                          - type: 'null'
                      views:
                        type: integer
                        minimum: -9007199254740991
                        maximum: 9007199254740991
                      claps:
                        type: integer
                        minimum: -9007199254740991
                        maximum: 9007199254740991
                      artwork_url:
                        type: string
                      artwork_source:
                        anyOf:
                          - type: string
                            enum:
                              - Custom
                              - Apple Music
                              - Spotify
                              - YouTube
                          - type: 'null'
                      credits:
                        type: array
                        items:
                          type: object
                          properties:
                            order:
                              anyOf:
                                - type: integer
                                  minimum: -9007199254740991
                                  maximum: 9007199254740991
                                - type: 'null'
                            artist:
                              type: object
                              properties:
                                id:
                                  type: integer
                                  minimum: -9007199254740991
                                  maximum: 9007199254740991
                                name:
                                  type: string
                                is_group:
                                  anyOf:
                                    - type: boolean
                                    - type: 'null'
                                avatar_url:
                                  anyOf:
                                    - type: string
                                    - type: 'null'
                              required:
                                - id
                                - name
                                - is_group
                                - avatar_url
                            role:
                              anyOf:
                                - type: object
                                  properties:
                                    id:
                                      type: integer
                                      minimum: -9007199254740991
                                      maximum: 9007199254740991
                                    title:
                                      type: string
                                    slug:
                                      anyOf:
                                        - type: string
                                        - type: 'null'
                                    tag:
                                      anyOf:
                                        - type: string
                                        - type: 'null'
                                  required:
                                    - id
                                    - title
                                    - slug
                                    - tag
                                - type: 'null'
                          required:
                            - order
                            - artist
                            - role
                      genres:
                        type: array
                        items:
                          type: object
                          properties:
                            id:
                              type: integer
                              minimum: -9007199254740991
                              maximum: 9007199254740991
                            slug:
                              anyOf:
                                - type: string
                                - type: 'null'
                            title:
                              type: string
                          required:
                            - id
                            - slug
                            - title
                      labels:
                        type: array
                        items:
                          type: object
                          properties:
                            id:
                              type: integer
                              minimum: -9007199254740991
                              maximum: 9007199254740991
                            name:
                              type: string
                          required:
                            - id
                            - name
                    required:
                      - id
                      - title
                      - slug
                      - released_at
                      - published_at
                      - views
                      - claps
                      - artwork_url
                      - artwork_source
                      - credits
                      - genres
                      - labels
                required:
                  - data
        '404':
          $ref: '#/components/responses/NotFound'
components:
  responses:
    NotFound:
      description: The requested resource does not exist, or is not public.
      content:
        application/json:
          schema:
            type: object
            properties:
              error:
                type: object
                properties:
                  code:
                    type: string
                    enum:
                      - not_found
                      - bad_request
                      - internal_error
                  message:
                    type: string
                required:
                  - code
                  - message
            required:
              - error

````