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

# Add an activity to a cart

> Books one more activity for the cart's guest. With `line.external_id`, the same body sent again answers the cart (`200`). A guest blacklisted since is refused. The guest is booked as on the booking portal — the day, the slot and the capacity are checked, a product the restaurant approves becomes a request (`PENDING`) — without the portal having to be open. `party_size` must be what the units cover. Times are `start_at` instants of `/activity-availability`. Forcing options need their scope. Requires `ACTIVITIES_WRITE`.



## OpenAPI

````yaml https://app.eat-now.io/api/partner/v1/openapi.json post /api/partner/v1/activity-carts/{id}/activities
openapi: 3.0.3
info:
  title: EatNow Partner API
  version: v1
  description: >-
    Version 1 of the EatNow partner API.


    This API is designed for trusted partner integrations that need
    restaurant-scoped access to availability, reservation management, and
    operational reference data.


    Authentication

    - Use `Authorization: Bearer <token>` with a partner API token created from
    the EatNow dashboard.

    - Access is controlled by credential scopes and each request is resolved to
    a single restaurant.


    Base URL

    - The server URL in this document is the canonical base URL for the current
    environment.


    Errors

    - Endpoint errors use `error.code`, `error.message`, and `error.request_id`.
    Errors raised before the endpoint, including rate limiting, may use another
    format.

    - Validation, authentication, authorization, conflicts, and not-found cases
    all use the same top-level error shape.


    Rate limits

    - An API key may send 300 requests per minute: past that, `429 RATE_LIMITED`
    with `Retry-After`, in seconds. The partner route rule also allows 600
    requests per minute per client IP. Back off on 429. When present,
    x-ratelimit-reset is an epoch timestamp in milliseconds.


    Public endpoints

    - `GET /api/partner/v1` and `GET /api/partner/v1/openapi.json` are public.

    - All business endpoints require Bearer authentication.
servers:
  - url: https://app.eat-now.io
security: []
tags:
  - name: Meta
    description: Platform metadata and schema endpoints
  - name: Authentication
    description: Credential validation and auth context endpoints
  - name: Availability
    description: Bookable slot search and exact slot validation
  - name: Catalog
    description: Reference data for restaurant tables, rooms, prescribers, and discounts
  - name: Reservations
    description: Reservation lookup, search, update, and cancellation
  - name: Customers
    description: >-
      Customer (CRM) records, independent of reservations: list, sync, create,
      update
  - name: Activities
    description: 'Booked activities (spa, excursions…): read and incremental sync'
  - name: Activity catalog
    description: >-
      Activity products, their slots and staff: what a reseller reads before it
      books
  - name: Gift cards
    description: >-
      Import and manage your own gift cards, or check and redeem any code at a
      till
  - name: Webhooks
    description: >-
      Webhook endpoints a key subscribes to V1 events (reservations, customers,
      activities, gift cards)
  - name: Missed Calls
    description: Report missed calls and trigger WhatsApp follow-up templates
externalDocs:
  description: Integration guides, authentication, errors, and webhook reference
  url: https://docs.eat-now.io/api-reference/introduction
paths:
  /api/partner/v1/activity-carts/{id}/activities:
    post:
      tags:
        - Activities
      summary: Add an activity to a cart
      description: >-
        Books one more activity for the cart's guest. With `line.external_id`,
        the same body sent again answers the cart (`200`). A guest blacklisted
        since is refused. The guest is booked as on the booking portal — the
        day, the slot and the capacity are checked, a product the restaurant
        approves becomes a request (`PENDING`) — without the portal having to be
        open. `party_size` must be what the units cover. Times are `start_at`
        instants of `/activity-availability`. Forcing options need their scope.
        Requires `ACTIVITIES_WRITE`.
      operationId: addPartnerActivity
      parameters:
        - schema:
            type: string
            minLength: 1
            description: Activity cart identifier.
          required: true
          description: Activity cart identifier.
          name: id
          in: path
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/PartnerApiActivityAddRequest'
      responses:
        '200':
          description: The cart, the activity added earlier under this `external_id`
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/PartnerApiActivityCartResponse'
        '201':
          description: The cart, with the activity added
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/PartnerApiActivityCartResponse'
        '400':
          description: Request validation failed (see `error.details.issues`).
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/PartnerApiError'
        '401':
          description: Authentication failed
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/PartnerApiError'
        '403':
          description: >-
            Scope is insufficient (required: `ACTIVITIES_WRITE`; `audience=all`
            also requires `ACTIVITIES_FORCE_INSERT`), or the restaurant does not
            have the activities module (`FEATURE_NOT_ENABLED`).
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/PartnerApiError'
        '404':
          description: No cart with this id in the restaurant.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/PartnerApiError'
        '409':
          description: >-
            `external_id` already used for another request
            (`details.existing_id`), or the customer was merged meanwhile.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/PartnerApiError'
        '422':
          description: >-
            The booking is refused: `details.reason` says why (`product`,
            `variant`, `extra`, `fields`, `contact`, `staff`, `day`, `slot`,
            `capacity`, `party`, `approval`, `blacklisted`,
            `start_at_not_representable`, `unknown_field`, `unknown_prescriber`)
            and `details.line` which line, from 0.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/PartnerApiError'
        '429':
          description: >-
            Rate limit exceeded: at most 300 requests per minute per API key
            (`RATE_LIMITED`, with a `Retry-After` header in seconds), and 600
            per minute per client IP for the partner route rule, whose
            middleware response may not use the PartnerApiError envelope or
            include request_id. Back off before retrying.
        '500':
          description: >-
            Unexpected server error. Preserve error.request_id for support.
            Before retrying a write, check whether it already succeeded.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/PartnerApiError'
      security:
        - PartnerBearerToken: []
components:
  schemas:
    PartnerApiActivityAddRequest:
      type: object
      properties:
        line:
          type: object
          properties:
            product_id:
              type: string
              minLength: 1
            start_at:
              type: string
              format: date-time
              description: >-
                Start of the activity, with its offset: one of the `start_at` of
                `/activity-availability`. An instant the restaurant's clock does
                not show (seconds, a time skipped or repeated when the clock
                changes) is refused.
            party_size:
              type: integer
              minimum: 1
              description: >-
                People taking part: the units booked times their
                `covers_per_unit` — or, for a formula (`per_cover: false`),
                within its covers.
            variants:
              type: array
              items:
                type: object
                properties:
                  variant_id:
                    type: string
                    minLength: 1
                  quantity:
                    type: integer
                    minimum: 1
                    maximum: 100
                required:
                  - variant_id
                  - quantity
                additionalProperties: false
              minItems: 1
              maxItems: 20
              description: 'What is booked: each variant of the product and its quantity.'
            extras:
              type: array
              items:
                type: object
                properties:
                  product_id:
                    type: string
                    minLength: 1
                  variant_id:
                    type: string
                    minLength: 1
                  quantity:
                    type: integer
                    minimum: 1
                    maximum: 100
                required:
                  - product_id
                  - variant_id
                  - quantity
                additionalProperties: false
              maxItems: 20
              default: []
              description: Add-ons of the product (`extras` in `/activity-products`).
            metadata:
              type: object
              additionalProperties:
                type: object
                properties:
                  name:
                    type: string
                    description: 'Ignored: the question''s own.'
                  value:
                    anyOf:
                      - type: string
                      - type: number
                      - type: boolean
                      - nullable: true
                      - type: array
                        items:
                          type: string
                required:
                  - value
                additionalProperties: false
              description: >-
                Answers to the product's questions, under their `key`
                (`field-0`, `field-1`…). A required question left out is
                refused.
            assigned_staff_id:
              type: string
              minLength: 1
              description: Who runs it (`/activity-staff`).
            external_id:
              type: string
              minLength: 1
              maxLength: 200
              description: Your reference of this activity, unique per restaurant.
          required:
            - product_id
            - start_at
            - party_size
            - variants
          additionalProperties: false
          description: >-
            The activity added. Its `external_id` identifies the request: the
            same again answers the activity booked.
        source:
          type: string
          enum:
            - WALK_IN
            - WEBSITE
            - PHONE
            - EMAIL
            - RESERVE_WITH_GOOGLE
            - TRAVEL_AGENCIES
            - OTHER
            - INSTAGRAM
            - FACEBOOK
            - TIKTOK
            - SNAPCHAT
            - WHATSAPP
            - TRIPADVISOR
            - PRIVATIZATION
            - MISSED_CALL
          default: OTHER
        comment:
          type: string
          nullable: true
          maxLength: 2000
        tags:
          type: array
          items:
            type: string
            minLength: 1
          maxItems: 20
        prescriber_id:
          type: string
          minLength: 1
          description: >-
            The prescriber the booking is credited to; its exclusive offers can
            be booked.
        audience:
          type: string
          enum:
            - public
            - all
          default: public
          description: >-
            `all`: internal and exclusive offers can be booked. Requires
            `ACTIVITIES_FORCE_INSERT`.
        payment:
          type: string
          enum:
            - none
            - payment_link
            - paid_elsewhere
          default: none
          description: >-
            `none`: everything is paid on site. `payment_link`: the lines owed
            online are left for the guest to pay; the activity awaits its
            payment, and the cart gives `payment_url`. `paid_elsewhere`: you
            took the money; each line is recorded paid at the catalog price
            (provider `PARTNER`), requires `PAYMENTS_WRITE` and
            `external_payment_reference`. Refused on a product to approve
            without `bypass_approval`.
        external_payment_reference:
          type: string
          minLength: 1
          maxLength: 200
          description: Your payment or order id, kept on each paid line.
        send_payment_link:
          type: boolean
          default: true
          description: >-
            With `payment_link`: emails or messages the link to the guest now.
            `false` when you pass on `payment_url` yourself. Needs
            `send_client_notifications`.
        bypass_availability:
          type: boolean
          default: false
          description: >-
            Takes a full slot, a time off the grid or a closed day — never one
            gone by. Requires `ACTIVITIES_FORCE_INSERT`.
        bypass_approval:
          type: boolean
          default: false
          description: >-
            Confirms a product the restaurant approves otherwise. Requires
            `ACTIVITIES_FORCE_CONFIRM`.
        send_client_notifications:
          type: boolean
          default: true
          description: >-
            Messages the guest now (confirmation or request) and later (reminder
            the day before). `false` when you tell the guest yourself.
        send_staff_notifications:
          type: boolean
          default: true
          description: >-
            Tells the restaurant's team, as an online booking does. `false`
            requires `ACTIVITIES_FORCE_INSERT`.
      required:
        - line
      additionalProperties: false
    PartnerApiActivityCartResponse:
      type: object
      properties:
        data:
          $ref: '#/components/schemas/PartnerApiActivityCart'
      required:
        - data
    PartnerApiError:
      type: object
      properties:
        error:
          type: object
          properties:
            code:
              $ref: '#/components/schemas/PartnerApiErrorCode'
            message:
              type: string
            request_id:
              type: string
            details:
              type: object
              additionalProperties:
                nullable: true
          required:
            - code
            - message
            - request_id
      required:
        - error
    PartnerApiActivityCart:
      type: object
      properties:
        id:
          type: string
        external_id:
          type: string
          nullable: true
        payment_url:
          type: string
          nullable: true
          description: >-
            The page where the guest pays what the cart owes online; `null` when
            nothing can be paid. Needs `ACTIVITIES_READ_SENSITIVE`: it carries
            the cart's link.
        activities:
          type: array
          items:
            $ref: '#/components/schemas/PartnerApiActivity'
      required:
        - id
        - external_id
        - payment_url
        - activities
    PartnerApiErrorCode:
      type: string
      enum:
        - AUTHENTICATION_REQUIRED
        - INVALID_AUTHENTICATION
        - INSUFFICIENT_SCOPE
        - FEATURE_NOT_ENABLED
        - RESTAURANT_SUSPENDED
        - VALIDATION_ERROR
        - RESOURCE_NOT_FOUND
        - RESOURCE_CONFLICT
        - PAYMENT_REQUIRED
        - RATE_LIMITED
        - INTERNAL_ERROR
    PartnerApiActivity:
      type: object
      properties:
        id:
          type: string
        cart_id:
          type: string
          description: >-
            The guest's visit: activities booked together share it (one payment
            page, one customer, one room).
        external_id:
          type: string
          nullable: true
          description: Your reference of this activity, set when you booked it.
        cart_external_id:
          type: string
          nullable: true
          description: Your reference of its cart, set when you booked it.
        status:
          type: string
          enum:
            - PENDING
            - REJECTED
            - CONFIRMED_PENDING_PAYMENT
            - CONFIRMED
            - SHOWED_UP
            - NO_SHOW
            - CANCELED_BY_RESTAURANT
            - CANCELED_BY_USER
        start_at:
          type: string
          format: date-time
        party_size:
          type: integer
          minimum: 0
        source:
          type: string
          enum:
            - WALK_IN
            - WEBSITE
            - PHONE
            - EMAIL
            - RESERVE_WITH_GOOGLE
            - TRAVEL_AGENCIES
            - OTHER
            - INSTAGRAM
            - FACEBOOK
            - TIKTOK
            - SNAPCHAT
            - WHATSAPP
            - TRIPADVISOR
            - PRIVATIZATION
            - MISSED_CALL
        product:
          $ref: '#/components/schemas/PartnerApiActivityProduct'
        variant:
          $ref: '#/components/schemas/PartnerApiActivityVariant'
        variants:
          type: array
          items:
            $ref: '#/components/schemas/PartnerApiActivityBookedVariant'
          description: >-
            What is booked: each variant of the product and its quantity, extras
            left out.
        assigned_staff:
          $ref: '#/components/schemas/PartnerApiActivityStaff'
        prescriber:
          $ref: '#/components/schemas/PartnerApiPrescriber'
        customer:
          $ref: '#/components/schemas/PartnerApiCustomer'
        hotel_guest:
          type: object
          nullable: true
          properties:
            room_number:
              type: string
              nullable: true
            pms_reference:
              $ref: '#/components/schemas/PartnerApiPmsReference'
          required:
            - room_number
            - pms_reference
          description: >-
            Set when the guest stays at the hotel. `room_number` and
            `pms_reference` are null without the sensitive view.
        additional_comment:
          type: string
          nullable: true
        metadata:
          type: object
          nullable: true
          additionalProperties:
            $ref: '#/components/schemas/PartnerApiMetadataField'
        attached_files:
          type: array
          items:
            type: string
        tags:
          type: array
          items:
            type: string
        cancellation_reason:
          type: string
          nullable: true
        payment_summary:
          $ref: '#/components/schemas/PartnerApiPaymentSummary'
        payments:
          type: array
          nullable: true
          items:
            $ref: '#/components/schemas/PartnerApiPayment'
        sensitive_data_included:
          type: boolean
        created_at:
          type: string
          format: date-time
        updated_at:
          type: string
          format: date-time
          description: >-
            Last change of the activity, its cart or its payment lines. Not an
            order of events: read the activity again to know its current state.
      required:
        - id
        - cart_id
        - external_id
        - cart_external_id
        - status
        - start_at
        - party_size
        - source
        - product
        - variant
        - variants
        - assigned_staff
        - prescriber
        - customer
        - hotel_guest
        - additional_comment
        - metadata
        - attached_files
        - tags
        - cancellation_reason
        - payment_summary
        - payments
        - sensitive_data_included
        - created_at
        - updated_at
    PartnerApiActivityProduct:
      type: object
      properties:
        id:
          type: string
        name:
          type: string
      required:
        - id
        - name
    PartnerApiActivityVariant:
      type: object
      nullable: true
      properties:
        id:
          type: string
        name:
          type: string
      required:
        - id
        - name
      description: >-
        The variant booked when there is exactly one; null when there are
        several (see `variants`).
    PartnerApiActivityBookedVariant:
      type: object
      properties:
        id:
          type: string
        name:
          type: string
        quantity:
          type: integer
          minimum: 0
      required:
        - id
        - name
        - quantity
    PartnerApiActivityStaff:
      type: object
      nullable: true
      properties:
        id:
          type: string
        name:
          type: string
      required:
        - id
        - name
      description: Who runs it (therapist, guide…), chosen by the staff.
    PartnerApiPrescriber:
      type: object
      nullable: true
      properties:
        id:
          type: string
        name:
          type: string
        phone_number:
          type: string
          nullable: true
      required:
        - id
        - name
        - phone_number
    PartnerApiCustomer:
      type: object
      nullable: true
      properties:
        id:
          type: string
          nullable: true
        name:
          type: string
          nullable: true
        email:
          type: string
          nullable: true
          format: email
        phone_number:
          type: string
          nullable: true
        lang:
          type: string
          nullable: true
          enum:
            - FR
            - EN
            - IT
            - ES
            - DE
            - PT
            - null
      required:
        - id
        - name
        - email
        - phone_number
        - lang
    PartnerApiPmsReference:
      type: object
      nullable: true
      properties:
        stay_id:
          type: string
          minLength: 1
          maxLength: 128
      required:
        - stay_id
      description: >-
        The stay in the hotel's property management system (PMS), when the visit
        is linked to one. Read: null without the sensitive view. Write: links
        the visit to a PMS stay; null unlinks it.
    PartnerApiMetadataField:
      type: object
      properties:
        name:
          type: string
        value:
          anyOf:
            - type: string
            - type: number
            - type: boolean
            - nullable: true
            - type: array
              items:
                type: string
      required:
        - name
        - value
    PartnerApiPaymentSummary:
      type: object
      properties:
        currency:
          type: string
          nullable: true
          enum:
            - MAD
            - EUR
            - USD
            - XOF
            - null
        total_amount:
          type: integer
        paid_amount:
          type: integer
        gift_card_amount:
          type: integer
        authorized_amount:
          type: integer
        pending_amount:
          type: integer
        refunded_amount:
          type: integer
        statuses:
          type: array
          items:
            type: string
            enum:
              - FREE
              - PENDING
              - PAID
              - EXPIRED
              - REFUNDED
              - CANCELED
              - AUTHORIZED
              - CAPTURED
              - CAPTURE_FAILED
              - VOIDED
              - DECLINED
      required:
        - currency
        - total_amount
        - paid_amount
        - gift_card_amount
        - authorized_amount
        - pending_amount
        - refunded_amount
        - statuses
    PartnerApiPayment:
      type: object
      properties:
        id:
          type: string
        provider_id:
          type: string
          nullable: true
        payment_type:
          type: string
          enum:
            - DEPOSIT
            - PREPAYMENT
            - EXTRA
            - NO_SHOW_FEE
            - GIFT_CARD
        payment_mode:
          type: string
          enum:
            - SOFT_PREAUTH
            - PREAUTH
            - POSTAUTH
        provider:
          type: string
          enum:
            - PAYZONE
            - CMI
            - STRIPE
            - CASH
            - WIRE_TRANSFER
            - DEBTOR
            - CREDIT_CARD
            - PARTNER
            - ROOM_CHARGE
            - GIFT_CARD
        status:
          type: string
          enum:
            - FREE
            - PENDING
            - PAID
            - EXPIRED
            - REFUNDED
            - CANCELED
            - AUTHORIZED
            - CAPTURED
            - CAPTURE_FAILED
            - VOIDED
            - DECLINED
        amount:
          type: integer
        gift_card_amount:
          type: integer
        quantity:
          type: integer
        unit_price:
          type: integer
        percent_of_total:
          type: number
        currency:
          type: string
          enum:
            - MAD
            - EUR
            - USD
            - XOF
        is_refundable:
          type: boolean
        external_reference:
          type: string
          nullable: true
          description: >-
            Reference of money taken outside EatNow (provider `PARTNER`): the
            partner's payment or order id.
        expiration_date:
          type: string
          nullable: true
          format: date-time
        max_cancellation_date:
          type: string
          nullable: true
          format: date-time
        authorized_at:
          type: string
          nullable: true
          format: date-time
        capture_deadline:
          type: string
          nullable: true
          format: date-time
        captured_at:
          type: string
          nullable: true
          format: date-time
        voided_at:
          type: string
          nullable: true
          format: date-time
        linked_product:
          $ref: '#/components/schemas/PartnerApiPaymentProduct'
        linked_variant:
          $ref: '#/components/schemas/PartnerApiPaymentProduct'
        created_at:
          type: string
          format: date-time
        updated_at:
          type: string
          format: date-time
      required:
        - id
        - provider_id
        - payment_type
        - payment_mode
        - provider
        - status
        - amount
        - gift_card_amount
        - quantity
        - unit_price
        - percent_of_total
        - currency
        - is_refundable
        - external_reference
        - expiration_date
        - max_cancellation_date
        - authorized_at
        - capture_deadline
        - captured_at
        - voided_at
        - linked_product
        - linked_variant
        - created_at
        - updated_at
    PartnerApiPaymentProduct:
      type: object
      nullable: true
      properties:
        id:
          type: string
        name:
          type: string
      required:
        - id
        - name
  securitySchemes:
    PartnerBearerToken:
      type: http
      scheme: bearer
      bearerFormat: API Token
      description: >-
        Restaurant-scoped partner API token passed as `Authorization: Bearer
        <token>`.
      x-default: your_token_here

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.