# HTTP request

HTTP request with configurable headers, method and JSON request body.

Canonical URL: https://opennodeflow.dev/wiki/reference-app-core-core-http/
JSON reference: https://opennodeflow.dev/wiki/reference-app-core-core-http/index.json
Source snapshot: 2026-10-23

# HTTP request

Performs a real HTTP request and exposes its response. Calls execute from the ONF host; retries can repeat externally visible effects.

## Inputs, outputs and configuration
- **exec** (control): gates execution when wired. **body** (any, optional): serialized as JSON for methods other than GET/HEAD; defaults to {} when absent/null.
- **data** (any): response text parsed as JSON when possible, otherwise the text string. **status** (number): HTTP status.
- **next** (control): success. **error** (control): optional exhausted-failure handler.
- **url** (required string): fresh default `https://example.com`.
- **method**: GET (default), POST, PUT, PATCH, DELETE or HEAD.
- **headers** (object): default {}; merged over Content-Type: application/json.
- **failOnError** (boolean): default true; false returns non-2xx responses normally.

## Example
For a JSON POST, set method POST and a placeholder service URL, supply body `{"message":"example"}`, then inspect data/status. GET and HEAD ignore body. A successful empty response produces an empty string rather than null.

## Failure and sensitive data
Network errors and body-reading failures throw. With failOnError enabled, non-2xx throws `HTTP <status>: <first 500 response characters>`. After retries, a wired error route handles failure, but data/status are cleared: its handler should read `context.errors` rather than require those data outputs. Otherwise the run fails.

URLs, headers, body and response can contain private data and enter saved configuration/history. This generic asset does not read secrets or checkpoint requests. For authorization, duplicate it and obtain secret values inside code; never paste real tokens into headers. A timeout/cancel cannot undo an accepted remote request.

## Catalog identity

| Field | Value |
| --- | --- |
| Source key | `app.core.core.http` |
| Kind | node |
| Family | app-core |
| Pack | See library discovery |

[Integration guide](/wiki/first-workflow/) · [Browse the catalog](/wiki/integration-catalog/)

## Inputs

| Socket ID | Label | Type | Required | Meaning |
| --- | --- | --- | --- | --- |
| `exec` | Execute | control | No |  |
| `body` | Body | any | No |  |

## Outputs

| Socket ID | Label | Type | Required | Meaning |
| --- | --- | --- | --- | --- |
| `next` | Next | control | No |  |
| `error` | On error | control | No |  |
| `data` | Data | any | No |  |
| `status` | Status | number | No |  |

## Configuration schema


```json
{
  "type": "object",
  "properties": {
    "url": {
      "type": "string",
      "title": "URL",
      "default": "https://example.com"
    },
    "method": {
      "type": "string",
      "title": "Method",
      "enum": [
        "GET",
        "POST",
        "PUT",
        "PATCH",
        "DELETE",
        "HEAD"
      ],
      "default": "GET"
    },
    "headers": {
      "type": "object",
      "title": "Headers",
      "default": {}
    },
    "failOnError": {
      "type": "boolean",
      "title": "Fail on HTTP error",
      "default": true
    }
  },
  "required": [
    "url"
  ]
}
```





## Source and installed versions

This reference describes the maintained source catalog snapshot, not a live export of your installation. Published definitions use immutable versions; installed graphs retain their exact pins. Discover and read the installed definition and selected version before wiring it. See [versioning](/wiki/versioning/), [connections](/wiki/connections/) and [integration setup](/wiki/integration-setup/).

---

## Documentation provenance

- `../OpenNodeFlow-Library/work/catalog-all.mjs`
- `../OpenNodeFlow-Library/work/azure-pack-consolidation-20261022/catalog-policy.mjs`
- `../OpenNodeFlow-Library/work/developer-packs-20261022/catalog.mjs`
- `shared/seed.ts`
- `shared/storage-library.ts`
- `shared/variable-library.ts`
- `shared/control-flow.ts`
- `shared/remote-routes.ts`
- `server/runtime-library.ts`
- `shared/error-library.ts`
- `shared/storage-model.ts`
- `shared/builtin-documentation.ts`

This page describes maintained source, not a live inventory or an authorization to perform actions.
