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

# APIs

> Reference index for all Livepeer APIs: the Video REST API, the AI gateway inference API, and the go-livepeer node CLI/metrics API.

export const TableCell = ({children, align = "left", header = false, style = {}, className = "", ...rest}) => {
  const Component = header ? "th" : "td";
  return <Component className={className} style={{
    padding: "0.75rem 1rem",
    textAlign: align,
    border: header ? "none" : "1px solid var(--lp-color-border-default)",
    ...style
  }} {...rest}>
      {children}
    </Component>;
};

export const TableRow = ({children, header = false, hover = false, style = {}, className = "", ...rest}) => {
  const rowId = `table-row-${Math.random().toString(36).substr(2, 9)}`;
  return <>
      {hover && <style>{`
          #${rowId}:hover {
            background-color: var(--lp-color-bg-card);
          }
        `}</style>}
      <tr id={rowId} className={className} style={{
    ...header && ({
      backgroundColor: "var(--lp-color-accent-strong)",
      color: "var(--lp-color-on-accent)",
      fontWeight: "bold"
    }),
    ...style
  }} {...rest}>
        {children}
      </tr>
    </>;
};

export const StyledTable = ({children, variant = "default", style = {}, className = "", ...rest}) => {
  const wrapperVariants = {
    default: {
      border: "1px solid var(--lp-color-border-default)",
      backgroundColor: "var(--lp-color-bg-card)",
      overflow: "hidden"
    },
    bordered: {
      border: "2px solid var(--lp-color-accent)",
      backgroundColor: "var(--lp-color-bg-page)",
      overflow: "hidden"
    },
    minimal: {
      border: "none",
      backgroundColor: "transparent",
      overflow: "visible"
    }
  };
  return <div data-docs-styled-table-shell className={className} style={{
    width: "100%",
    padding: 0,
    margin: 0,
    ...wrapperVariants[variant],
    ...style
  }} {...rest}>
      <table data-docs-styled-table style={{
    width: "100%",
    borderCollapse: "collapse",
    borderSpacing: 0,
    margin: 0,
    backgroundColor: "transparent"
  }}>
        {children}
      </table>
    </div>;
};

export const CenteredContainer = ({children, maxWidth = "800px", padding = "0", preset = "default", width = "", minWidth = "", marginRight = "", marginBottom = "", textAlign = "", style = {}, className = "", ...rest}) => {
  const presets = {
    default: {},
    fitContent: {
      width: "fit-content",
      minWidth: "fit-content"
    },
    readable70: {
      width: "70%",
      minWidth: "fit-content"
    },
    readable80: {
      width: "80%",
      minWidth: "fit-content"
    },
    readable90: {
      width: "90%"
    },
    wide900: {
      maxWidth: "900px"
    }
  };
  const presetStyle = presets[preset] || presets.default;
  return <div className={className} style={{
    maxWidth: presetStyle.maxWidth || maxWidth,
    margin: "0 auto",
    padding: padding,
    ...presetStyle.width ? {
      width: presetStyle.width
    } : {},
    ...presetStyle.minWidth ? {
      minWidth: presetStyle.minWidth
    } : {},
    ...width ? {
      width
    } : {},
    ...minWidth ? {
      minWidth
    } : {},
    ...marginRight ? {
      marginRight
    } : {},
    ...marginBottom ? {
      marginBottom
    } : {},
    ...textAlign ? {
      textAlign
    } : {},
    ...style
  }} {...rest}>
      {children}
    </div>;
};

export const CustomDivider = ({color = "var(--lp-color-border-default)", middleText = "", spacing = "default", style = {}, className = "", ...rest}) => {
  const spacingPresets = {
    default: {
      margin: "24px 0"
    },
    overlap: {
      margin: "-1rem 0 -1rem 0"
    },
    tight: {
      margin: "0 0 -1rem 0"
    },
    section: {
      margin: "0 0 -2rem 0"
    },
    sectionOverlap: {
      margin: "-1rem 0 -2rem 0"
    },
    deepOverlap: {
      margin: "-1rem 0 -1.5rem 0"
    }
  };
  const spacingStyle = spacingPresets[spacing] || spacingPresets.default;
  return <div role="separator" aria-orientation="horizontal" className={className} style={{
    display: "flex",
    alignItems: "center",
    ...spacingStyle,
    fontSize: style?.fontSize || "16px",
    height: "fit-content",
    ...style
  }} {...rest}>
      <span style={{
    marginRight: "var(--lp-spacing-px-8)",
    opacity: 0.2
  }}>
        <Icon icon="/snippets/assets/logos/Livepeer-Logo-Symbol-Theme.svg" />
      </span>
      <div style={{
    flex: 1,
    height: "1px",
    background: "var(--lp-color-border-default)",
    opacity: 0.4
  }}></div>
      {middleText && <>
          <Icon icon="circle" size={2} />
          <span style={{
    margin: "0 8px",
    fontWeight: "bold",
    color: color,
    opacity: 0.7
  }}>
            {middleText}
          </span>
          <Icon icon="circle" size={2} />
        </>}
      <div style={{
    flex: 1,
    height: "1px",
    background: "var(--lp-color-border-default)",
    opacity: 0.4
  }}></div>
      <span style={{
    marginLeft: "var(--lp-spacing-px-8)",
    opacity: 0.2
  }}>
        <span style={{
    display: "inline-block",
    transform: "scaleX(-1)"
  }}>
          <Icon icon="/snippets/assets/logos/Livepeer-Logo-Symbol-Theme.svg" />
        </span>
      </span>
    </div>;
};

export const LinkArrow = ({href, label, description, newline = true, borderColor, className = '', style = {}, ...rest}) => {
  const linkArrowStyle = {
    display: 'inline-flex',
    alignItems: 'center',
    justifyContent: 'center',
    gap: "var(--lp-spacing-1)",
    width: 'fit-content',
    ...borderColor && ({
      borderColor
    })
  };
  return <span className={className} style={style} {...rest}>
      {newline && <br />}
      <span style={linkArrowStyle}>
        <a href={href} target="_blank" rel="noopener noreferrer">
          {label}
        </a>
        <Icon icon="arrow-up-right" size={14} color="var(--lp-color-accent)" />
      </span>
      {description && description}
      {description && <div style={{
    height: "var(--lp-spacing-3)"
  }} />}
    </span>;
};

<CenteredContainer preset="readable90">
  <Tip>Three distinct APIs exist on Livepeer. The Video REST API manages streams and assets. The AI gateway API runs inference jobs. The go-livepeer node API exposes CLI operations and Prometheus metrics. They have separate base URLs and authentication schemes.</Tip>
</CenteredContainer>

***

<CustomDivider />

## Livepeer Video REST API

The Video REST API covers stream management, VOD asset upload and playback, webhooks, access control, viewership metrics, and transcode jobs. It is the API the Video SDK family (`livepeer` npm/pip/go/maven packages) wraps.

**Base URL:** `https://livepeer.com/api`

**Authentication:** Bearer token in the `Authorization` header. API keys are managed in the Livepeer developer dashboard.

**OpenAPI spec:** The full machine-readable specification is available from the Livepeer developer portal (OpenAPI 3.0).

**Key resource groups:**

<StyledTable variant="bordered">
  <thead>
    <TableRow header>
      <TableCell header>Resource</TableCell>
      <TableCell header>Base path</TableCell>
      <TableCell header>Purpose</TableCell>
    </TableRow>
  </thead>

  <tbody>
    <TableRow>
      <TableCell>Streams</TableCell>
      <TableCell>`/stream`</TableCell>
      <TableCell>Create, read, update, terminate live streams; retrieve sessions</TableCell>
    </TableRow>

    <TableRow>
      <TableCell>Assets</TableCell>
      <TableCell>`/asset`</TableCell>
      <TableCell>Upload, transcode, retrieve, and delete VOD assets</TableCell>
    </TableRow>

    <TableRow>
      <TableCell>Playback</TableCell>
      <TableCell>`/playback`</TableCell>
      <TableCell>Retrieve playback info by playback ID</TableCell>
    </TableRow>

    <TableRow>
      <TableCell>Webhooks</TableCell>
      <TableCell>`/webhook`</TableCell>
      <TableCell>Create and manage event subscriptions</TableCell>
    </TableRow>

    <TableRow>
      <TableCell>Multistream targets</TableCell>
      <TableCell>`/multistream/target`</TableCell>
      <TableCell>Register RTMP restream destinations</TableCell>
    </TableRow>

    <TableRow>
      <TableCell>Access control</TableCell>
      <TableCell>`/access-control/signing-key`</TableCell>
      <TableCell>Create and manage JWT signing keys</TableCell>
    </TableRow>

    <TableRow>
      <TableCell>Viewership</TableCell>
      <TableCell>`/data/views`</TableCell>
      <TableCell>Query engagement and performance metrics</TableCell>
    </TableRow>

    <TableRow>
      <TableCell>Tasks</TableCell>
      <TableCell>`/task`</TableCell>
      <TableCell>Monitor async transcoding jobs</TableCell>
    </TableRow>
  </tbody>
</StyledTable>

<CustomDivider />

## AI Gateway Inference API

The AI inference API is served by the Livepeer gateway for AI workloads. Each pipeline type has a dedicated endpoint. The gateway routes requests to network orchestrators running the `ai-runner` container.

**Base URL:** Gateway-dependent. Community gateway: `https://dream-gateway.livepeer.cloud`. Self-hosted gateways use the configured HTTP address.

**Authentication:** Bearer token when the gateway requires it; the community gateway accepts unauthenticated requests for development.

**OpenAPI spec:** Generated from the `ai-runner` OpenAPI specification. Available at `https://docs.livepeer.org/api/ai-worker.yaml`.

**Pipeline endpoints:**

| Endpoint               | Method | Pipeline                              |
| ---------------------- | ------ | ------------------------------------- |
| `/text-to-image`       | POST   | Text prompt to image                  |
| `/image-to-image`      | POST   | Image + prompt to transformed image   |
| `/image-to-video`      | POST   | Image to short video                  |
| `/image-to-text`       | POST   | Image to caption                      |
| `/audio-to-text`       | POST   | Audio to transcript                   |
| `/text-to-speech`      | POST   | Text to audio                         |
| `/upscale`             | POST   | Image upscaling                       |
| `/segment-anything-2`  | POST   | Image segmentation                    |
| `/llm`                 | POST   | OpenAI-compatible chat completions    |
| `/live/video-to-video` | POST   | Real-time AI stream session (trickle) |

See <LinkArrow href="/v2/developers/build/ai-and-agents/ai-pipelines" label="AI Pipelines" newline={false} /> for endpoint schemas and curl examples.

<CustomDivider />

## Go-Livepeer Node API

go-livepeer nodes expose two local HTTP interfaces: the CLI interface (used by `livepeer_cli`) and the Prometheus metrics endpoint.

**CLI interface:** `http://<cliAddr>/` (default: `http://127.0.0.1:7935/`)

Used by `livepeer_cli` for node management operations: deposit funding, status queries, configuration updates.

**Metrics endpoint:** `http://<cliAddr>/metrics`

Exposes Prometheus-format metrics for scraping. Enable with the `-metrics` flag on node startup. See <LinkArrow href="/v2/developers/guides/observability-and-debugging/tooling-and-metrics" label="Tooling and Metrics" newline={false} /> for the key metric names and monitoring setup.

The node API is local-only by default. Do not expose it externally without access controls.

<CustomDivider />

## Related Pages

<CardGroup cols={2}>
  <Card title="SDKs" icon="code" href="/v2/developers/resources/reference/sdks" arrow horizontal>
    SDK packages that wrap the Video and AI APIs.
  </Card>

  <Card title="AI Pipelines" icon="cpu" href="/v2/developers/build/ai-and-agents/ai-pipelines" arrow horizontal>
    AI inference API endpoint shapes and request schemas.
  </Card>

  <Card title="Access Control" icon="lock" href="/v2/developers/guides/auth-and-security/access-control" arrow horizontal>
    Access control signing key API for JWT-gated playback.
  </Card>

  <Card title="Viewership" icon="chart" href="/v2/developers/guides/observability-and-debugging/tooling-and-metrics" arrow horizontal>
    Viewership metrics API for engagement and performance data.
  </Card>
</CardGroup>
