> ## Documentation Index
> Fetch the complete documentation index at: https://developer.runa.io/llms.txt
> Use this file to discover all available pages before exploring further.

# Order completion

> Order completion events are triggered when an order has completed processing.

<Card title="Webhook overview" href="/reference/webhooks" icon="graduation-cap" horizontal arrow>
  Webhooks work differently to the API endpoints. Take a read of our guide to
  understand how they work.
</Card>

This event is essential when using the async ordering mode if you need to take action when an order has completed processing. It's also useful if you want to feed ordering data into your system.

The webhook payload depends on whether the order was processed successfully or not. You should use the `status` field to determine the type of payload you have received.

* Successfully completed orders will have a `status` of `COMPLETED`
* Failed orders will have a `status` of `FAILED`


## OpenAPI

````yaml reference/2024-02-05/openapi.json WEBHOOK order.completion
openapi: 3.1.1
info:
  title: Runa
  version: '2.0'
  description: The public Runa API
  license:
    name: Ⓒ Runa
    url: https://runa.io/terms-of-use
  contact:
    name: Runa
    url: https://runa.io
    email: info@runa.io
servers:
  - url: https://playground.runa.io/v2
    description: Playground
  - url: https://api.runa.io/v2
    description: Production
security:
  - ApiKeyAuth: []
tags:
  - name: utility
    description: Utility endpoints.
  - name: balance
    description: Operations related to account balance.
  - name: products
    description: Operations related to products.
  - name: orders
    description: Operations related to ordering and orders.
externalDocs:
  url: https://developer.runa.com/reference
  description: Runa API Reference
paths: {}
components:
  securitySchemes:
    ApiKeyAuth:
      type: apiKey
      in: header
      name: X-Api-Key
      description: >-
        Your API key. See the [API key](/getting-started/api-key) page on
        details of how to generate and store your keys.

````