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

# Add a Manual RTMP Destination to Ogh

> Configure a custom RTMP or RTMPS server as a streaming destination in Ogh — no provider account required.

A manual RTMP destination lets you stream to any server that accepts an RTMP or RTMPS ingest URL and stream key. Use this when you want to reach a platform that Ogh does not have a built-in provider for, or when you prefer to manage credentials yourself without connecting an account. Manual destinations are entirely self-contained: Ogh encrypts everything on your device and no external service is involved.

<Note>
  RTMPS encrypts your stream key and video in transit. Plain RTMP does not. Use
  RTMPS whenever your destination supports it.
</Note>

## Destination fields

<ParamField path="name" type="string" required>
  A human-readable label for this destination. Must be non-blank after trimming
  whitespace, and at most **50 characters** long.
</ParamField>

<ParamField path="rtmp_url" type="string" required>
  The ingest server URL provided by your streaming platform. Must start with
  `rtmp://` or `rtmps://` and include a valid hostname. An optional port
  (1–65535) and path are also accepted — for example
  `rtmps://live.example.com:443/app`.
</ParamField>

<ParamField path="stream_key" type="string" required>
  The secret key that identifies your channel or stream on the server. Must be
  non-blank and contain no spaces, tabs, or newlines.
</ParamField>

<ParamField path="enabled" type="boolean" default="true">
  Whether this destination participates in streaming sessions. You can toggle it
  at any time while the app is idle.
</ParamField>

## Add a destination

<Steps>
  <Step title="Open Settings">
    Launch Ogh. If no destination exists yet, Settings opens automatically.
    Otherwise, tap the **Settings** icon from the Preview screen.
  </Step>

  <Step title="Tap Destinations">
    In the Settings menu, tap **Destinations** to view your saved manual
    destinations.
  </Step>

  <Step title="Tap Add Destination">
    Tap the **Add Destination** button to open the destination form.
  </Step>

  <Step title="Enter your destination details">
    Fill in a **Name**, your **RTMP URL**, and your **Stream Key**. All three
    fields are required. Refer to your streaming platform's dashboard for the
    ingest URL and key.
  </Step>

  <Step title="Tap Save">
    Tap **Save**. Ogh validates your input, then encrypts the destination record
    and stores it on your device. The new destination appears in the Destinations
    list and is enabled by default.
  </Step>
</Steps>

## Endpoint format

When you start a session, Ogh builds the full ingest endpoint by joining the
RTMP URL and stream key with exactly one slash:

```
rtmps://live.example.com/app + stream_key_here
→ rtmps://live.example.com/app/stream_key_here
```

If your RTMP URL already ends with a `/`, Ogh appends the key directly without
adding another slash. This matches the standard `{server}/{app}/{key}` format
expected by most ingest servers.

## RTMP URL validation rules

Ogh accepts a URL when all of the following are true:

* The scheme is `rtmp://` or `rtmps://`.
* A valid hostname follows the scheme. The hostname may contain letters,
  digits, dots, underscores, and hyphens.
* If a port is present, it must be a number between **1** and **65535**.
* An optional path may follow the hostname (and port). Path segments may
  contain letters, digits, dots, underscores, hyphens, and forward slashes.

## Stream key validation rules

A stream key is accepted when it is non-blank and contains no whitespace
characters (spaces, tabs, newlines, and similar) and no control characters.

## Edit and delete a destination

Tap any destination in the Destinations list to open its edit form. Change any
field and tap **Save** to apply your updates.

To delete a destination, open it for editing and tap **Delete**. Ogh asks you to
confirm before removing the record permanently.

## Security

Your stream key is encrypted with **AES-256-GCM** using a non-exportable key
stored in Android Keystore. The key is never written to disk in plaintext, never
included in logs, and never transmitted to any Ogh server — Ogh does not operate
one. The encrypted record is stored in private app storage and excluded from
Android cloud backup and device transfer.
