---
title: "Test External Api Request"
method: POST
path: "/v1/flow_automation/test_external_api_request"
tags: ["flow_automation"]
---

# Test External Api Request

`POST /v1/flow_automation/test_external_api_request`

## Request

- Base URL: `https://api.linktodm.com` (the document declares no server; this is the origin it was published from)
- URL: `https://api.linktodm.com/v1/flow_automation/test_external_api_request`
- Auth: HTTP bearer

Run an EXTERNAL_API_REQUEST config once, server-side (the browser
can't call third-party endpoints directly because of CORS).

## Request body

- TestExternalApiRequestPayload: Payload for the server-side 'Test Request' of an EXTERNAL_API_REQUEST action. Runs on the API (not the browser) so third-party endpoints without CORS headers still work.
  - `url` string, required
  - `method` 'GET' | 'POST' | 'PUT' | 'PATCH' | 'DELETE' | 'HEAD' | 'OPTIONS': HTTP verb for an EXTERNAL_API_REQUEST. POST is the default. GET/HEAD/OPTIONS requests never send a body.
  - `headers` object, nullable
  - `body` string, nullable

## Response `200`

Successful Response

- TestExternalApiRequestResponse: Result of a test request. `error` is set when the request itself failed (network/timeout/invalid URL); otherwise status/headers/body describe the third-party response.
  - `ok` boolean, required
  - `status_code` integer, nullable
  - `elapsed_ms` integer, nullable
  - `headers` object
  - `body` string
  - `resolved_url` string
  - `resolved_body` string
  - `error` string, nullable

## Other responses

- `422`: Validation Error

---

[API](https://skmtc.dev/linktodm/apis/salesmorph.md) - [All operations](https://skmtc.dev/linktodm/apis/salesmorph/llms.txt) - [OpenAPI document](https://skmtc.dev/linktodm/apis/salesmorph/revisions/4af0ad5dbe92?raw)
