Skip to main content
POST
/
backends
/
http_response
Create
curl --request POST \
  --url https://api.ngrok.com/backends/http_response \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --header 'ngrok-version: <ngrok-version>' \
  --data '{
  "description": "<string>",
  "metadata": "<string>",
  "body": "<string>",
  "headers": {},
  "status_code": 123
}'
{
  "id": "<string>",
  "uri": "<string>",
  "created_at": "<string>",
  "description": "<string>",
  "metadata": "<string>",
  "body": "<string>",
  "headers": {},
  "status_code": 123
}

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Headers

ngrok-version
integer
default:2
required

Body

application/json
description
string

human-readable description of this backend. Optional

metadata
string

arbitrary user-defined machine-readable data of this backend. Optional

body
string

body to return as fixed content

headers
object

headers to return

status_code
integer

status code to return

Response

201 - application/json

n/a

id
string

n/a

uri
string

URI of the HTTPResponseBackend API resource

created_at
string

timestamp when the backend was created, RFC 3339 format

description
string

human-readable description of this backend. Optional

metadata
string

arbitrary user-defined machine-readable data of this backend. Optional

body
string

body to return as fixed content

headers
object

headers to return

status_code
integer

status code to return