Payhawk icon

Payhawk

Interact with the Zitadel API

Actions99

Overview

This node updates an existing purchase order in a system via an API. It is useful when you need to modify details of a purchase order such as changing the note, updating the supplier information, or altering the currency used for the purchase order. Typical scenarios include correcting errors in purchase orders, adding additional notes after creation, or adjusting financial details before final approval.

For example, if a purchase order was created with the wrong currency or missing supplier details, this node allows you to update those fields without creating a new purchase order from scratch.

Properties

Name Meaning
Account Id Identifier of the account associated with the purchase order (required).
Purchase Order Id Identifier of the purchase order to update (required).
Note A textual note from the creator of the purchase order; can be used to add or update comments.
Supplier JSON object representing the expense category or supplier details related to the purchase order.
Currency Currency code for the purchase order. Options include AED, USD, EUR, GBP, JPY, and many others (see full list in properties).

Output

The node outputs a JSON object representing the updated purchase order. This typically includes all the fields of the purchase order after the update has been applied, such as the updated note, supplier information, currency, and identifiers.

No binary data output is indicated for this operation.

Dependencies

  • Requires an API key credential or similar authentication token configured in n8n to authorize requests to the external service managing purchase orders.
  • The node uses a base URL provided by credentials to send HTTP requests.
  • The node depends on the external API described in the bundled OpenAPI specification (payhawk.api.json), which must be accessible and properly configured.

Troubleshooting

  • Missing Required Fields: Errors may occur if Account Id or Purchase Order Id are not provided. Ensure these required fields are set.
  • Invalid JSON in Supplier Field: Since the supplier property expects JSON, invalid JSON input will cause parsing errors. Validate JSON format before input.
  • Unsupported Currency Code: Using a currency code not listed in the options may result in API rejection. Use one of the supported currency codes.
  • Authentication Failures: If the API key or authentication token is missing or invalid, the request will fail. Verify credentials configuration.
  • Network or API Errors: Connectivity issues or API downtime can cause failures. Check network connectivity and API status.

Links and References

  • ISO 4217 Currency Codes — Reference for currency codes supported.
  • Documentation for the external purchase order API (not included here) should be consulted for detailed field descriptions and error codes.

Discussion