basicAuth
Set Authorization Basic on later HTTP requests
Resolves username and password, then stores Authorization: Basic <base64(user:pass)> in httpAuthHeaders. Later http nodes on this run send that header unless they set Authorization themselves.
This node does not send a request. The wire is passthrough. The password is not included in this node’s output. Prefer {{secrets.*}} (or {{input.*}}) for credentials. Empty password after template resolve fails at execute time.
If a bearer ran earlier, this helper overwrites Authorization (same header name). In the sample, that is after me and mycart already used Bearer.
Typical chain: … → mycart (still Bearer) → listProducts (skipInheritedAuth) → basicAuth → http (now Basic). Sample: auth-helpers.flow.json.
Data
| Field | Type | Description |
|---|---|---|
label | string | Optional UI label |
username | string | Templated username |
password | string | Required; templated |
Input / output
| Value | |
|---|---|
| Execute input | Previous node output (passthrough) |
| Output | Same as input; credentials not echoed |
| Vars | Merges httpAuthHeaders.Authorization for following HTTP nodes |
Examples
Input → basicAuth → HTTP
Previous node puts credentials on the run payload (or use secrets). Next HTTP has no Authorization header.
start → creds (input) → basic (basicAuth) → call (http GET)
{
"id": "creds",
"type": "input",
"data": {
"value": { "username": "emilys", "password": "emilyspass" }
}
}
{
"id": "basic",
"type": "basicAuth",
"data": {
"username": "{{input.username}}",
"password": "{{input.password}}"
}
}
{
"id": "call",
"type": "http",
"data": {
"method": "GET",
"url": "{{env.API_BASE}}/protected",
"headers": {}
}
}
Inspect call’s request snapshot for Authorization: Basic …. The basic step output must not contain the password.
Secrets instead of input
{
"type": "basicAuth",
"data": {
"username": "{{secrets.username}}",
"password": "{{secrets.password}}"
}
}