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

# Quickstart

You'll need an API key from [**Settings**](https://app.arklow.io/dashboard/settings?tab=keys).

<Steps>
  <Step title="Create an Action">
    Actions define the work your platform performs. Create one on the [**New Action**](https://app.arklow.io/dashboard/actions/new) page with the variant `orders.created`.
  </Step>

  <Step title="Add an SDK destination">
    Create an [SDK destination](/resources/destinations/sdk/index) on the [**Destinations**](https://app.arklow.io/dashboard/destinations) page: set **Destination Type** to **SDK** and enter the namespace `quickstart`. [Other destination types](/resources/destinations/index) deliver over HTTP or to Pub/Sub.
  </Step>

  <Step title="Link them">
    Open the action's **Flow** tab and use **Link destination** to attach the newly created SDK Destination.
  </Step>

  <Step title="Start a listener">
    The listener claims deliveries for its namespace and hands each one to your handler.

    <Tabs>
      <Tab title="TypeScript">
        ```typescript theme={null}
        import Listener from "@arklow/sdk-ts/listener";

        const listener = new Listener({ apiKey: process.env.ARKLOW_API_KEY! });

        const running = listener.listen(
          { namespace: "quickstart" },
          async (delivery) => {
            console.log(delivery.variant, delivery.payload);
            await delivery.ack();
          },
        );
        ```
      </Tab>

      <Tab title="Python">
        The package `arklow-sdk-py` imports as `arklow`.

        ```python theme={null}
        import asyncio
        import os

        from arklow import Listener


        async def main() -> None:
            listener = Listener(api_key=os.environ["ARKLOW_API_KEY"])

            async def handle(delivery) -> None:
                print(delivery.variant, delivery.payload)
                await delivery.ack()

            listener.listen(handle, namespace="quickstart", max_outstanding=16)
            await asyncio.Event().wait()


        asyncio.run(main())
        ```
      </Tab>
    </Tabs>

    `ack()` settles the action as succeeded. A handler that returns without settling acks; an unhandled error nacks, and the attempt is redelivered.
  </Step>

  <Step title="Send work">
    One POST to [ingress](/resources/sources/arklow/ingress) creates the action.

    ```bash theme={null}
    curl -X POST https://ingress.arklow.io/v1/ingress/orders.created \
      -H "X-Arklow-Auth: $ARKLOW_API_KEY" \
      -H "Content-Type: application/json" \
      -d '{"order_id": "8471", "total": 129.50}'
    ```

    [SQS](/resources/sources/aws/sqs) and [Pub/Sub](/resources/sources/gcp/pubsub) sources ingest into the same action from queues you already run.
  </Step>

  <Step title="Acknowledge the Action">
    When your handler finishes its work, it automatically acknowledges. If the work should be handled asynchronously, see [Deferring work](/fundamentals/acknowledgement-and-deferral).
  </Step>
</Steps>

## Next steps

<CardGroup cols={2}>
  <Card title="SDK" icon="code" href="/resources/destinations/sdk/index">
    Listener options, settlement, leases, and external work.
  </Card>

  <Card title="How Arklow works" icon="puzzle-piece" href="/fundamentals/overview">
    The path work takes from source to settlement.
  </Card>
</CardGroup>
