Skip to content

Commit 04d3ed6

Browse files
Update workflows.mdx
1 parent 8256c8f commit 04d3ed6

File tree

1 file changed

+22
-6
lines changed

1 file changed

+22
-6
lines changed

docs-v2/pages/connect/workflows.mdx

Lines changed: 22 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -239,29 +239,45 @@ We plan to improve this interface in the future, and potentially allow developer
239239

240240
## Testing workflow steps
241241

242-
To test a step that uses the connected account of one of your end users in the builder, you'll need a few things to be configured so that your workflow knows which account to use for the test.
242+
To test a step using the connected account of one of your end users in the builder, you'll need a few things to be configured so that your workflow knows which account to use.
243243

244-
**Make sure you have an external user with the relevant connected accounts saved to your project:**
244+
**Make sure you have an external user with the relevant connected account(s) saved to your project:**
245245
- Go to the **[Users tab](/connect#users)** in the **Connect** section of your project to confirm
246-
- If not, you can [easily connect one in the UI](#connect-a-test-account)
246+
- If not, either connect one from your application or [directly in the UI](#connect-a-test-account)
247247

248248
**Pass the environment and external user ID:**
249249
1. Once you've added an HTTP trigger to the workflow, click **Generate test event**
250+
<Image src="https://res.cloudinary.com/pipedreamin/image/upload/v1733533191/generate-test-event-cta_emoykg.png" alt="Generate test event" width={600} height={529} />
250251
2. Click on the **Headers** tab
251252
3. Make sure `x-pd-environment` is set (you'll likely want to `development`)
252253
4. Make sure to also pass `x-pd-external-user-id` with the external user ID of the user you'd like to test with
253254

255+
<Image src="https://res.cloudinary.com/pipedreamin/image/upload/v1733533298/pd-connect-headers_c1x7an.png" alt="Include required headers" width={600} height={529} />
256+
254257
## Troubleshooting
255258

256-
<Callout type="info">
257259
For help debugging issues with your workflow, you can return verbose error messages to the caller by configuring the HTTP trigger to **Return a custom response from your workflow**.
258260

259261
<Image src="https://res.cloudinary.com/pipedreamin/image/upload/v1733461258/custom-response_gu3x47.png" alt="Configure custom response" width={600} height={529} />
260262

261-
</Callout>
263+
With that setting enabled on the trigger, below is an example of [this](/connect/workflows#required-account-not-found-for-external-user-id) error:
262264

263-
### Common errors
265+
```bash
266+
curl -X POST https://{your-endpoint-url} \
267+
-H 'Content-Type: application/json' \
268+
-H 'Authorization: Bearer {access_token}' \
269+
-H "x-pd-environment: development" \
270+
-H "x-pd-external-user-id: abc-123" \
271+
-d '{
272+
"slackChannel": "#general",
273+
"messageText": "Hello, world! (sent via curl)",
274+
"hubSpotList": "prospects",
275+
"contactEmail": "[email protected]"
276+
}' \
277+
Pipedream Connect Error: Required account for hubspot not found for external user ID abc-123 in development
278+
```
264279
280+
### Common errors
265281
#### No external user ID passed, but one or more steps require it
266282
- One or more steps in the workflow are configured to **Use end user's auth via Connect**, but no external user ID was passed when invoking the workflow.
267283
- [Refer to the docs](#invoke-the-workflow) to make sure you're passing external user ID correctly when invoking the workflow.

0 commit comments

Comments
 (0)