# Creating an Order

Now that the user has completed the `BookingForm`, it is time to create the `Order`. The following method will create the `Order` which you can then present to the user for review.

{% tabs %}
{% tab title="iOS" %}

```swift
Traveler.createOrder(bookingForm: bookingForm) { (order, error) in

}
```

Alternatively you can use the delegate pattern

```swift
Traveler.createOrder(bookingForm: bookingForm, delegate: self)
```

```swift
extension MyViewController: OrderCreateDelegate {
    func orderCreationDidSucceed(_ order: Order) {
    
    }
    
    func orderCreationDidFail(_ error: Error) {
    
    }
}
```

{% endtab %}

{% tab title="Android" %}

```java
Traveler.createOrder(bookingForm, new OrderCreateCallback() {
    @Override
    void onOrderCreateSuccess(Order order) {
    
    }

    @Override
    void onOrderCreateFailure(Error error) {
    
    }
});
```

{% endtab %}
{% endtabs %}


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.guestlogix.io/traveler/mobile-sdks/stripe-payment-sdk/creating-an-order.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
