> To build or manage a Wix site with an AI agent, follow https://www.wix.com/headless/skill.md
> It builds a new Wix site or puts your own site online, from a prompt, and keeps changing it afterwards. The pages are code in any web technology, and Wix runs the backend.
> It works through the Wix plugin (the Wix MCP and the Wix skills), the Wix CLI or no Wix login, and puts the site live on Wix hosting or on another host.
> Business features include a store, bookings, events and tickets, a restaurant, a blog, forms, members and many more.
> Read the Wix skills online at https://www.wix.com/skills
> 
> Portal Navigation:
> 
> - Append `.md` to any URL under `https://dev.wix.com/docs/` to get its markdown version.
> - Pages are either content pages (article or reference text) or menu pages (a list of links to child pages).
> - To get a menu page, truncate any URL to a parent path and append `.md` (e.g. `https://dev.wix.com/docs/sdk.md`, `https://dev.wix.com/docs/sdk/core-modules.md`).
> - If a reference page seems to be missing its schema (parameters, return types, or type definitions), append `?schema=true` to its `.md` URL (e.g. `https://dev.wix.com/docs/contexts/contexts/stores/category-info/use-category-info-context.md?schema=true`).
> - Top-level index of all portals: https://dev.wix.com/docs/llms.txt
> - Full concatenated docs: https://dev.wix.com/docs/llms-full.txt

# QueryArrivals

# Package: arrivals

# Namespace: ArrivalsService

# Method link: https://dev.wix.com/docs/api-reference/business-solutions/bookings/arrivals/arrival/query-arrivals.md

## Permission Scopes:
SCOPE.ARRIVALS.READ-ARRIVALS: SCOPE.ARRIVALS.READ-ARRIVALS

## Introduction

Retrieves a list of up to 100 arrivals, given the provided paging, filtering, and sorting.

Query Arrivals runs with these defaults, which you can override:

- `id` is sorted in `ASC` order
- `cursorPaging.limit` is `50`

Supported filter and sort fields: `id`, `contactDetails.contactId`,
`source.identifiedBy`, `area.id`, `area.locationId`, `area.entranceId`, `eligibilityDetails.issues`, `planBenefit.poolId`,
`planBenefit.benefitKey`, `planBenefit.type`, `status`, `createdDate`. Filter only, not sort: `overriddenBy.wixUserId`.
`eligibilityDetails.issues` is a list: filter it with `$hasSome` or `$hasAll`, for example
`{ "eligibilityDetails.issues": { "$hasSome": ["INTAKE_FORM_MISSING"] } }` for the arrivals where a
form was missing; filtering on it requires the `SCOPE.ARRIVALS.READ-ELIGIBILITY-DETAILS` permission scope, like reading it.
An arrival a site user overrode has `status` `GRANTED` and `overriddenBy`, and an `overrideReason` only when a site user gave
one. To find overrides, filter `overriddenBy.wixUserId` with a `createdDate` lower bound:
`{ "overriddenBy.wixUserId": { "$exists": true }, "createdDate": { "$gte": "2026-11-09T00:00:00Z" } }` finds
every override since that time, and a user ID in place of `$exists` finds those of one site user.

`status`, `source.identifiedBy`, `eligibilityDetails.issues`, `planBenefit.poolId`, `planBenefit.benefitKey`,
`planBenefit.type` and `overriddenBy.wixUserId` have no index. A filter on any of them, or a sort on any but `overriddenBy.wixUserId` (filter only), must also have a lower
bound on `createdDate` (`$gt` or `$gte`) no more than 400 days ago, at the top level or in an `$and`; otherwise the
request fails with `CREATED_DATE_LOWER_BOUND_REQUIRED`. A bound inside an `$or` counts only when every branch has one. A next page,
requested with its cursor, is not checked again.

To learn about working with Query methods, see [API Query Language](https://dev.wix.com/docs/api-reference/articles/work-with-wix-apis/data-retrieval/about-the-wix-api-query-language.md) and [Sorting and Paging](https://dev.wix.com/docs/api-reference/articles/work-with-wix-apis/data-retrieval/about-sorting-and-paging.md).

---

## REST API

### Schema

```
 Method: queryArrivals
 Description: Retrieves a list of up to 100 arrivals, given the provided paging, filtering, and sorting.  Query Arrivals runs with these defaults, which you can override:  - `id` is sorted in `ASC` order - `cursorPaging.limit` is `50`  Supported filter and sort fields: `id`, `contactDetails.contactId`, `source.identifiedBy`, `area.id`, `area.locationId`, `area.entranceId`, `eligibilityDetails.issues`, `planBenefit.poolId`, `planBenefit.benefitKey`, `planBenefit.type`, `status`, `createdDate`. Filter only, not sort: `overriddenBy.wixUserId`. `eligibilityDetails.issues` is a list: filter it with `$hasSome` or `$hasAll`, for example `{ "eligibilityDetails.issues": { "$hasSome": ["INTAKE_FORM_MISSING"] } }` for the arrivals where a form was missing; filtering on it requires the `SCOPE.ARRIVALS.READ-ELIGIBILITY-DETAILS` permission scope, like reading it. An arrival a site user overrode has `status` `GRANTED` and `overriddenBy`, and an `overrideReason` only when a site user gave one. To find overrides, filter `overriddenBy.wixUserId` with a `createdDate` lower bound: `{ "overriddenBy.wixUserId": { "$exists": true }, "createdDate": { "$gte": "2026-11-09T00:00:00Z" } }` finds every override since that time, and a user GUID in place of `$exists` finds those of one site user.  `status`, `source.identifiedBy`, `eligibilityDetails.issues`, `planBenefit.poolId`, `planBenefit.benefitKey`, `planBenefit.type` and `overriddenBy.wixUserId` have no index. A filter on any of them, or a sort on any but `overriddenBy.wixUserId` (filter only), must also have a lower bound on `createdDate` (`$gt` or `$gte`) no more than 400 days ago, at the top level or in an `$and`; otherwise the request fails with `CREATED_DATE_LOWER_BOUND_REQUIRED`. A bound inside an `$or` counts only when every branch has one. A next page, requested with its cursor, is not checked again.  To learn about working with Query methods, see [API Query Language](https://dev.wix.com/docs/api-reference/articles/work-with-wix-apis/data-retrieval/about-the-wix-api-query-language.md) and [Sorting and Paging](https://dev.wix.com/docs/api-reference/articles/work-with-wix-apis/data-retrieval/about-sorting-and-paging.md).
 URL: https://www.wixapis.com/arrivals/v1/arrivals/query
 Method: POST
 Method parameters:
   param name: query | type: CursorQuery    
     - name: cursorPaging | type: CursorPaging | description: Cursor paging options.  Learn more about [cursor paging](https://dev.wix.com/docs/rest/articles/getting-started/api-query-language.md#cursor-paging).  
        - name: limit | type: integer | description: Maximum number of items to return in the results.  | validation: minimum 0, maximum 100, format int32
        - name: cursor | type: string | description: Pointer to the next or previous page in the list of results.  Pass the relevant cursor token from the `pagingMetadata` object in the previous call's response. Not relevant for the first request.  | validation: maxLength 16000
        - name: filter | type: object | description: Filter object.  Learn more about the [filter section](https://dev.wix.com/docs/rest/articles/getting-started/api-query-language.md#the-filter-section).  
        - name: sort | type: array<Sorting> | description: Sort object.  Learn more about the [sort section](https://dev.wix.com/docs/rest/articles/getting-started/api-query-language.md#the-sort-section).  | validation: maxItems 5
           - name: fieldName | type: string | description: Name of the field to sort by.  | validation: maxLength 512
           - name: order | type: SortOrder | description: Sort order.  
                 - enum: ASC, DESC
 Query fields:
   - field: id | operators: $eq, $ne, $in, $exists, $gt, $gte, $lt, $lte, $startsWith | sort: ASC, DESC | aggregatable: undefined | searchable: undefined
   - field: contactDetails.contactId | operators: $eq, $ne, $in, $exists, $gt, $gte, $lt, $lte, $startsWith | sort: ASC, DESC | aggregatable: undefined | searchable: undefined
   - field: source.identifiedBy | operators: $eq, $ne, $in, $exists | sort: ASC, DESC | aggregatable: undefined | searchable: undefined
   - field: area.id | operators: $eq, $ne, $in, $exists, $gt, $gte, $lt, $lte, $startsWith | sort: ASC, DESC | aggregatable: undefined | searchable: undefined
   - field: area.locationId | operators: $eq, $ne, $in, $exists, $gt, $gte, $lt, $lte, $startsWith | sort: ASC, DESC | aggregatable: undefined | searchable: undefined
   - field: area.entranceId | operators: $eq, $ne, $in, $exists, $gt, $gte, $lt, $lte, $startsWith | sort: ASC, DESC | aggregatable: undefined | searchable: undefined
   - field: eligibilityDetails.issues | operators: none | sort: ASC, DESC | aggregatable: undefined | searchable: undefined
   - field: planBenefit.poolId | operators: $eq, $ne, $in, $exists, $gt, $gte, $lt, $lte, $startsWith | sort: ASC, DESC | aggregatable: undefined | searchable: undefined
   - field: planBenefit.benefitKey | operators: $eq, $ne, $in, $exists, $gt, $gte, $lt, $lte, $startsWith | sort: ASC, DESC | aggregatable: undefined | searchable: undefined
   - field: planBenefit.type | operators: $eq, $ne, $in, $exists | sort: ASC, DESC | aggregatable: undefined | searchable: undefined
   - field: status | operators: $eq, $ne, $in, $exists | sort: ASC, DESC | aggregatable: undefined | searchable: undefined
   - field: createdDate | operators: $eq, $ne, $in, $exists, $gt, $gte, $lt, $lte | sort: ASC, DESC | aggregatable: undefined | searchable: undefined
   - field: overriddenBy.wixUserId | operators: $eq, $ne, $in, $exists, $gt, $gte, $lt, $lte, $startsWith | sort: none | aggregatable: undefined | searchable: undefined
 Return type: QueryArrivalsResponse
  - name: arrivals | type: array<Arrival> | description: Retrieved arrivals.  
     - ONE-OF: 
        - name: planBenefit | type: PlanBenefit | description: The Pricing Plans benefit the entry was taken from: a credit pack or an unlimited plan (`type`). Redeemed in Pricing Plans after the arrival is written, after an override too.  | read-only: true 
           - name: poolId | type: string | description: GUID of the Pricing Plans benefit pool the member holds: the plan or pack they bought. Read-only to Arrivals.  | read-only: true | validation: format GUID
           - name: benefitKey | type: string | description: Key of the benefit inside the pool, as Pricing Plans defines it; a pool can hold several benefits. Read-only to Arrivals.  | read-only: true | validation: minLength 1, maxLength 64
           - name: displayName | type: string | description: Name to display, in the site's language ("10-Class Pack", "Monthly Unlimited"). The owner's own wording; not translated.  | read-only: true | validation: maxLength 200
           - name: type | type: PlanBenefitType | description: Whether the benefit counts entries: a credit pack spends a credit per entry, an unlimited plan counts nothing. Set by the server from the benefit's configuration in Pricing Plans.  | read-only: true 
                 - enum:
                 -     CREDIT: A credit pack: the benefit carries a credit configuration in Pricing Plans, and redeeming an entry spends one credit from its balance ("10-Class Pack").
                 -     UNLIMITED: An unlimited plan: no credit configuration, nothing is counted ("Monthly Unlimited"). The plan's own usage policy (a fixed interval, a rate limit such as three entries a week) may still apply, and Pricing Plans enforces it. Whether the plan is paid once or by subscription is not what this says.
        - name: scheduledEvent | type: ScheduledEvent | description: The scheduled event the person was booked into. Nothing is redeemed for one, and Arrivals doesn't mark its attendance: a business that wants it marked sets up an automation on the "Client arrives" trigger.  | read-only: true 
           - name: eventId | type: string | description: GUID of the scheduled event, as the provider in `appId` knows it. For an event from the Wix Calendar, the GUID in the Wix Calendar Events API.  | read-only: true | validation: minLength 1, maxLength 250
           - name: displayName | type: string | description: Name to display, in the site's language ("Tue 18:00 Reformer"). Not translated.  | read-only: true | validation: maxLength 200
           - name: appId | type: string | description: App GUID of the provider the event came from: the app that owns it on the Wix Calendar, such as Wix Bookings. Scheduled events are read from the Wix Calendar today; a provider of scheduled events of its own may later supply them, and is then identified here.  | read-only: true | validation: format GUID
     - name: id | type: string | description: Arrival GUID. Returned by Create Arrival; Override Arrival as Granted names it.  | read-only: true | validation: format GUID
     - name: revision | type: string | description: Revision number, which increments by 1 each time the arrival is updated: when a site user overrides a denied arrival (with Override Arrival as Granted, or with a repeat of Create Arrival within 5 seconds that carries `denialOverride`), and when a CRM contact merge moves the arrival to the surviving contact.  | read-only: true | validation: format int64
     - name: createdDate | type: string | description: Date and time the arrival was written, right after the person was evaluated at the entrance. For a granted arrival that was not overridden, it is the time the person was let in; for one that a site user overrode afterwards, it is the denial's time, and the override's time is `overriddenDate`; for one let in with `denialOverride` on the Create Arrival call that wrote it, it is the time the arrival was written, a moment after its `overriddenDate`.  | read-only: true | validation: format date-time
     - name: updatedDate | type: string | description: Date and time the arrival was updated. Equal to `createdDate` until a site user overrides the arrival or a contact merge moves it. For the time of the override itself, read `overriddenDate`, which a later merge does not move.  | read-only: true | validation: format date-time
     - name: contactDetails | type: ContactDetails | description: Who arrived: the contact, with their name and picture as Contacts held them when the arrival was written. Always present. On Create Arrival only `contactDetails.contactId` is sent; the server fills in the rest.  
        - name: contactId | type: string | description: GUID of the contact who arrived. The only field of `contactDetails` sent when creating an arrival.  | validation: format GUID
        - name: firstName | type: string | description: The contact's first name at the time of the arrival. Set by the server; personal data. `****` after the contact's personal data is deleted for privacy.  | read-only: true | validation: maxLength 1000
        - name: lastName | type: string | description: The contact's last name at the time of the arrival. Set by the server; personal data. `****` after the contact's personal data is deleted for privacy.  | read-only: true | validation: maxLength 1000
        - name: picture | type: Image | description: The contact's profile picture at the time of the arrival, as Contacts held it. Set by the server; personal data. Absent when the contact has none, and absent after the contact's personal data is deleted for privacy.  | read-only: true 
           - name: id | type: string | description: WixMedia image GUID.  | validation: maxLength 256
           - name: url | type: string | description: Image URL.  | validation: format WEB_URL
           - name: height | type: integer | description: Original image height.  | read-only: true 
           - name: width | type: integer | description: Original image width.  | read-only: true 
           - name: altText | type: string | description: Image alt text.  | validation: maxLength 1000
           - name: filename | type: string | description: Image filename.  | read-only: true | validation: maxLength 256
     - name: source | type: ArrivalSource | description: How the arrival came to be, and who created it. Set by the server.  | read-only: true 
        - name: identifiedBy | type: IdentificationMethod | description: How the person was identified: `BY_TOKEN` when a pass token was presented and the arrival was written by Create Arrival By Credential, `BY_CONTACT` when the arrival was written by contact GUID with nothing presented. Who wrote the arrival (a Wix user, or an app such as a reader at an entrance) is `createdBy`.  
             - enum:
             -     BY_TOKEN: A pass token was presented at the entrance: a QR code scanned by a site collaborator in a scanner app, or by a reader; `createdBy` says which. The arrival was written by [Create Arrival By Credential](https://dev.wix.com/docs/api-reference/business-solutions/bookings/arrivals/arrival/create-arrival-by-credential.md) with `token`.
             -     BY_CONTACT: Written by contact ID with nothing presented (from the contact card in the dashboard, or by an app), even when the contact holds a credential.
        - name: createdBy | type: IdentificationData | description: Who created the arrival, from the call identity: a Wix user (`wixUserId`), such as a site collaborator in a scanner app or an owner on the contact card, or an app (`appId`), such as a reader at an entrance or a partner app. This, not `identifiedBy`, is what tells a Wix user from an app, such as a reader or a partner app. Only `wixUserId` or `appId` is ever set; `anonymousVisitorId` and `memberId` never appear on an arrival, since members and visitors can't create arrivals. Who let the person in against a denial is `overriddenBy`, not this field.  
           - ONE-OF: 
              - name: anonymousVisitorId | type: string | description: GUID of a site visitor who hasn't logged in to the site.  | validation: format GUID
              - name: memberId | type: string | description: GUID of a site visitor who has logged in to the site.  | validation: format GUID
              - name: wixUserId | type: string | description: GUID of a Wix user. For example, the site owner or a [site collaborator](https://support.wix.com/en/article/inviting-people-to-contribute-to-your-site).  | validation: format GUID
              - name: appId | type: string | description: GUID of an app.  | validation: format GUID
     - name: area | type: AreaInfo | description: The area the person entered and the entrance they came in through, with the area's name and location and the entrance's name as they were at the time of the arrival. On Create Arrival only `area.entranceId` is sent; the server finds the area the entrance belongs to and fills in the rest.  
        - name: id | type: string | description: GUID of the area. Set by the server: the area the entrance belongs to.  | read-only: true | validation: format GUID
        - name: locationId | type: string | description: GUID of the business location the area belonged to at the time of the arrival, from the Locations API. Kept on the record so history survives an area moving to another location.  | read-only: true | validation: format GUID
        - name: name | type: string | description: Name of the area at the time of the arrival, kept on the record so history still reads right after the area is renamed.  | read-only: true | validation: minLength 1, maxLength 100
        - name: entranceId | type: string | description: GUID of the entrance the person came in through, one of an area's `entrances[].id`. The one field of `area` sent when creating an arrival.  | validation: format GUID
        - name: entranceName | type: string | description: Name of the entrance at the time of the arrival, kept on the record so history still reads right after the entrance is renamed or removed.  | read-only: true | validation: minLength 1, maxLength 100
     - name: eligibilityDetails | type: EligibilityDetails | description: What the engine found, from which `status` was derived: the issues of the entry as a whole, the intake forms the person is missing, and every plan benefit and scheduled event it found for the area, each with its own issue. Set by the server at creation and never changed afterwards: an override keeps it, so its `issues` hold what was overridden. Returned only to callers with the `SCOPE.ARRIVALS.READ-ELIGIBILITY-DETAILS` permission scope, since it says why a person was not eligible; filtering on `eligibilityDetails.issues` requires the same scope. Every response that carries an arrival leaves it out for other callers, Create Arrival and Create Arrival By Credential included: an app without the permission, such as a reader at an entrance, gets `status` and not the reason.  | read-only: true 
        - name: issues | type: array<EntryIssue> | description: The issues of the entry as a whole. The issues decide the status the evaluation gives: `GRANTED` when there are none, or only `INTAKE_FORM_MISSING` for forms that do not block entry; `DENIED` otherwise. When a site user lets the person in (afterwards with Override Arrival as Granted, or beforehand with `denialOverride` on Create Arrival), the status is `GRANTED` whatever the issues, and the issues show what was overridden. On an arrival, `PRICING_PLANS_UNAVAILABLE` and `CONTACTS_UNAVAILABLE` are found only that way, with `denialOverride`, since otherwise Create Arrival fails with `UNAVAILABLE`; Check Eligibility reports them without failing. A `DENIED` arrival always has at least one. Empty when nothing stood in the way.  | validation: maxItems 3
             - enum:
             -     NO_ELIGIBLE_GRANT: No grant the person holds admits them into this area now. A grant is what can grant entry: a plan benefit (`planBenefits`) or a scheduled event they are booked on (`scheduledEvents`), the same two kinds an arrival records in `planBenefit` or `scheduledEvent` once granted. Either nothing was found (`planBenefits` and `scheduledEvents` are empty), or everything found has an issue of its own, which says why. A contact whose site member's status (`memberInfo.status` in Contacts) is `BLOCKED`, `DELETED` or `OFFLINE` holds no plans here, so it finds none. Also reported when a credit pack would admit but the person is booked on an event here and now that still waits for approval: no credit is spent while the booking may be approved moments later (the event carries `PENDING_CONFIRMATION`). Declines at creation; site collaborators override, or sell a plan, approve the booking or renew the plan and create a new arrival. Not reported when Pricing Plans or Contacts did not answer: `PRICING_PLANS_UNAVAILABLE` or `CONTACTS_UNAVAILABLE` takes its place.
             -     INTAKE_FORM_MISSING: Not reported yet, since intake forms aren't checked at entry. Once they are, it means the person has no valid submission for at least one intake form the area's policy requires: never submitted, expired, canceled, or pending approval. The forms are listed in `missingIntakeForms`. Declines at creation when a missing form has `blocksEntry`; otherwise grants, with the issue kept on the arrival so site collaborators can chase the paperwork.
             -     RECENT_ENTRY: The person was already granted entry into this area within the last 15 minutes and a credit would be spent again: a retried scan, a re-entry, or a guest on the same credential. The earlier entry counts whatever granted it: a credit, an unlimited plan, a scheduled event or an override, and the 15 minutes count from that arrival's `createdDate`, or for an overridden arrival from its `overriddenDate`, when a site user let the person in. Declines at creation; the override spends a credit. Reported only when this entry would spend a credit: not when an unlimited plan or a scheduled event admits now.
             -     PRICING_PLANS_UNAVAILABLE: Pricing Plans didn't answer (it couldn't be reached, didn't answer in time, or failed on its side; any of these is an outage), so plan benefits were not checked. On an arrival, only on one let in by Create Arrival with `denialOverride`, since without a site user's decision the call fails with `UNAVAILABLE` instead and no denied arrival is written; Check Eligibility reports it without failing; Override Arrival as Granted does not call Pricing Plans. `planBenefits` is empty, no `planBenefit` is recorded and nothing is redeemed; scheduled events and intake forms are still evaluated. Reported instead of `NO_ELIGIBLE_GRANT`, never with it: plan benefits were not checked, so the person may hold one that admits. An issue a scheduled event has of its own stays on that event in `eligibilityDetails`.
             -     CONTACTS_UNAVAILABLE: Contacts didn't answer (it couldn't be reached, didn't answer in time, or failed on its side; any of these is an outage), so the person's member is unknown and plan benefits were not checked. On an arrival, only on one let in by Create Arrival with `denialOverride`, since without a site user's decision the call fails with `UNAVAILABLE` instead and no denied arrival is written; Check Eligibility reports it without failing. `planBenefits` is empty, no `planBenefit` is recorded, nothing is redeemed, and `contactDetails` has the contact ID alone, with no name or picture; scheduled events, read by contact, are still evaluated. Reported instead of `NO_ELIGIBLE_GRANT` and `PRICING_PLANS_UNAVAILABLE`, never with them: Pricing Plans is not read without the member.
        - name: missingIntakeForms | type: array<MissingIntakeForm> | description: Every intake form the area's policy requires and the person has no valid submission for, with its `blocksEntry`, so an app can point site collaborators to the right form. Empty unless `issues` contains `INTAKE_FORM_MISSING`, so always empty for now: intake forms aren't checked at entry yet.  | validation: maxItems 20
           - name: formId | type: string | description: GUID of the intake form, from the Intake Forms API, as listed in the area's policy.  | validation: format GUID
           - name: blocksEntry | type: boolean | description: Whether this missing form blocks entry, as configured on the area's policy (`policy.intakeForms[].blocksEntry` in the Areas API). `false`: the arrival is granted and site collaborators are warned. `true`: the arrival is denied until the form is submitted; site collaborators can still override.  
        - name: planBenefits | type: array<PlanBenefitEligibility> | description: The person's Pricing Plans benefits allowed into this area, each a `planBenefit` with its own `issues`: empty means the benefit admits. Listed on a `DENIED` arrival too, admitting ones included, so an override can take one later. The grant picks one by the rule on the arrival's `planBenefit` and records it there. Listed in the order of that rule, so the first is the one a grant takes; at most 20 are listed, the first 20 in that order. Empty when the person holds no benefit for this area, and when the status of the contact's site member (`memberInfo.status` in Contacts) is `BLOCKED`, `DELETED` or `OFFLINE`, since such a member holds no plans here.  | validation: maxItems 20
           - name: planBenefit | type: PlanBenefit | description: The benefit found, as `planBenefit` records it on an arrival.  | read-only: true 
           - name: issues | type: array<PlanBenefitIssue> | description: Why the benefit does not admit, in Pricing Plans' own words where it has one. Empty: the benefit admits. At most one is reported, since Pricing Plans gives one reason.  | read-only: true | validation: maxItems 1
                 - enum:
                 -     PLAN_NOT_ACTIVE: The benefit's plan isn't active at the time of the entry (ended, canceled, paused, not started yet, or for a moment while it's being renewed), as Pricing Plans reports. Site collaborators override, or renew the plan and create a new arrival.
                 -     NOT_ENOUGH_BALANCE: A credit pack with no credits left, as Pricing Plans reports. Site collaborators override, or sell credits and create a new arrival.
                 -     OUTSIDE_ACCESS_HOURS: The plan's usage policy does not allow entry at this hour or on this day, or another rule of the plan refuses entry, as Pricing Plans reports. A used-up limit on its own is `USAGE_LIMIT_REACHED`.
                 -     USAGE_LIMIT_REACHED: The plan's usage policy limits how often it can be used, such as three entries a week, and that limit is used up for the current period, as Pricing Plans reports. Site collaborators override, or the client comes back in the next period.
        - name: scheduledEvents | type: array<ScheduledEventEligibility> | description: The scheduled events the person is booked on at this area's location inside the area's entry window, each with its own `issues`: empty means the event admits. Listed on a `DENIED` arrival too, admitting ones included, so an override can take one later. Check Eligibility with a `scheduledEventSearchWindow` also lists the events that start inside that window, with `OUTSIDE_ENTRY_WINDOW`; Create Arrival never does. At most 20 are listed: the events inside the area's window first, then the others by start time, earliest first. Always empty while the area's `scheduledEventsPolicy.entryGrantingAppIds` is empty.  | validation: maxItems 20
           - name: scheduledEvent | type: ScheduledEvent | description: The event found, as `scheduledEvent` records it on an arrival.  | read-only: true 
           - name: issues | type: array<ScheduledEventIssue> | description: Why the event does not admit. Empty: the event admits. At most one is reported: when both apply, `OUTSIDE_ENTRY_WINDOW` wins over `PENDING_CONFIRMATION`, since approving the booking would not help outside the window.  | read-only: true | validation: maxItems 1
                 - enum:
                 -     PENDING_CONFIRMATION: The person is booked on the event here and now, but the booking still waits for the business's approval. Only an appointment can be pending. A credit pack is not spent instead (`NO_ELIGIBLE_GRANT`), since the booking may be approved moments later; an unlimited plan allowed into the area still admits. Site collaborators approve the booking and create a new arrival, or override.
                 -     OUTSIDE_ENTRY_WINDOW: The person is booked on the event, but now is outside the area's entry window for it (`policy.scheduledEventsPolicy.entryWindow` in the Areas API). Only on an event listed by a Check Eligibility with `scheduledEventSearchWindow`; never on an arrival, since Create Arrival does not find events outside the area's window.
     - name: status | type: Status | description: Whether access was given. Set by the server: by Create Arrival, from the issues (`GRANTED` despite them when the call carries `denialOverride`), and moved from `DENIED` to `GRANTED` by Override Arrival as Granted. Never sent by a caller.  | read-only: true 
         - enum:
         -     GRANTED: Access was given: the person entered. Either the engine found no issue that blocks entry, or a site user overrode a denial, afterwards with Override Arrival as Granted or on Create Arrival with `denialOverride`; `eligibilityDetails.issues` then holds what was overridden.
         -     DENIED: Access was not given: the engine found an issue that declines (see `EntryIssue`), and no site user has overridden it. A site user may still override with Override Arrival as Granted, which moves the status to `GRANTED`.
     - name: overrideReason | type: string | description: Why a site user let the person in against the issues, in their own words. Optional; written by Override Arrival as Granted, or from `denialOverride.reason` when Create Arrival let the person in despite a denial, so it can be present only on a `GRANTED` arrival with issues; either way the actor is `overriddenBy`. Free text that may describe the person, so it is personal data: `****` after the contact's personal data is deleted for privacy. It is returned only to callers with the `SCOPE.ARRIVALS.READ-ELIGIBILITY-DETAILS` permission scope.  | read-only: true | validation: maxLength 500
     - name: overriddenBy | type: IdentificationData | description: Who let the person in against a denial: the caller of Override Arrival as Granted, or of Create Arrival with `denialOverride`. Set by the server; present only on an arrival a site user let in against a denial, absent on every other arrival. Always a Wix user (`wixUserId`), since only site users may override. Who wrote the arrival is `source.createdBy`; the two can differ.  | read-only: true 
     - name: overriddenDate | type: string | description: Date and time a site user let the person in against a denial, set once with `overriddenBy`: when Override Arrival as Granted granted the arrival, or the time Create Arrival evaluated the person when it let them in with `denialOverride` on the call that wrote it: a moment before that arrival's `createdDate`, which is stamped when the arrival is written. Set by the server; absent on every arrival no site user overrode. A later contact merge moves `updatedDate` but never this.  | read-only: true | validation: format date-time
  - name: pagingMetadata | type: CursorPagingMetadata | description: Paging metadata.  
     - name: count | type: integer | description: Number of items returned in current page.  | validation: format int32
     - name: cursors | type: Cursors | description: Cursor strings that point to the next page, previous page, or both.  
        - name: next | type: string | description: Cursor string pointing to the next page in the list of results.  | validation: maxLength 16000
        - name: prev | type: string | description: Cursor pointing to the previous page in the list of results.  | validation: maxLength 16000
     - name: hasNext | type: boolean | description: Whether there are more pages to retrieve following the current page.  + `true`: Another page of results can be retrieved. + `false`: This is the last page.  

 Possible Errors:
   HTTP Code: 400 | Status Code: INVALID_ARGUMENT | Application Code: CREATED_DATE_LOWER_BOUND_REQUIRED | Description: The filter or sort uses a field with no index (`status`, `source.identifiedBy`, `eligibilityDetails.issues`, `planBenefit.poolId`, `planBenefit.benefitKey`, `planBenefit.type` or `overriddenBy.wixUserId`) without a lower bound on `createdDate` (`$gt` or `$gte`) no more than 400 days ago.


```

### Examples

### Query Arrivals
Lists today's denied arrivals at a location, newest first

```curl
curl -X POST \
  'https://www.wixapis.com/arrivals/v1/arrivals/query' \
  -H 'Authorization: <AUTH>' \
  -H 'Content-Type: application/json' \
  --data-binary '{
    "query": {
      "filter": {
        "area.locationId": "0b3fa0a1-6f0a-4a5e-9e64-2b7a4a6f0c11",
        "status": "DENIED",
        "createdDate": { "$gte": "2026-09-09T00:00:00Z" }
      },
      "sort": [{ "fieldName": "createdDate", "order": "DESC" }],
      "cursorPaging": { "limit": 50 }
    }
  }'
```

---

## JavaScript SDK

### Schema

```
 Method: wixClientAdmin.arrivals.arrivals.queryArrivals(query)
 Description: Retrieves a list of up to 100 arrivals, given the provided paging, filtering, and sorting.  Query Arrivals runs with these defaults, which you can override:  - `id` is sorted in `ASC` order - `cursorPaging.limit` is `50`  Supported filter and sort fields: `id`, `contactDetails.contactId`, `source.identifiedBy`, `area.id`, `area.locationId`, `area.entranceId`, `eligibilityDetails.issues`, `planBenefit.poolId`, `planBenefit.benefitKey`, `planBenefit.type`, `status`, `createdDate`. Filter only, not sort: `overriddenBy.wixUserId`. `eligibilityDetails.issues` is a list: filter it with `$hasSome` or `$hasAll`, for example `{ "eligibilityDetails.issues": { "$hasSome": ["INTAKE_FORM_MISSING"] } }` for the arrivals where a form was missing; filtering on it requires the `SCOPE.ARRIVALS.READ-ELIGIBILITY-DETAILS` permission scope, like reading it. An arrival a site user overrode has `status` `GRANTED` and `overriddenBy`, and an `overrideReason` only when a site user gave one. To find overrides, filter `overriddenBy.wixUserId` with a `createdDate` lower bound: `{ "overriddenBy.wixUserId": { "$exists": true }, "createdDate": { "$gte": "2026-11-09T00:00:00Z" } }` finds every override since that time, and a user GUID in place of `$exists` finds those of one site user.  `status`, `source.identifiedBy`, `eligibilityDetails.issues`, `planBenefit.poolId`, `planBenefit.benefitKey`, `planBenefit.type` and `overriddenBy.wixUserId` have no index. A filter on any of them, or a sort on any but `overriddenBy.wixUserId` (filter only), must also have a lower bound on `createdDate` (`$gt` or `$gte`) no more than 400 days ago, at the top level or in an `$and`; otherwise the request fails with `CREATED_DATE_LOWER_BOUND_REQUIRED`. A bound inside an `$or` counts only when every branch has one. A next page, requested with its cursor, is not checked again.  To learn about working with Query methods, see [API Query Language](https://dev.wix.com/docs/api-reference/articles/work-with-wix-apis/data-retrieval/about-the-wix-api-query-language.md) and [Sorting and Paging](https://dev.wix.com/docs/api-reference/articles/work-with-wix-apis/data-retrieval/about-sorting-and-paging.md).
 # Note: If the parameter `a.b` is listed under required parameters, `b` is only required if `a` is also present.
 Required parameters:  query
 Method parameters: 
   param name: query | type: ArrivalQuery   | required: true 
     - name: cursorPaging | type: CursorPaging | description: Cursor paging options.  Learn more about [cursor paging](https://dev.wix.com/docs/rest/articles/getting-started/api-query-language.md#cursor-paging).  
        - name: limit | type: integer | description: Maximum number of items to return in the results.  | validation: minimum 0, maximum 100, format int32
        - name: cursor | type: string | description: Pointer to the next or previous page in the list of results.  Pass the relevant cursor token from the `pagingMetadata` object in the previous call's response. Not relevant for the first request.  | validation: maxLength 16000
        - name: filter | type: object | description: Filter object.  Learn more about the [filter section](https://dev.wix.com/docs/rest/articles/getting-started/api-query-language.md#the-filter-section).  
        - name: sort | type: array<Sorting> | description: Sort object.  Learn more about the [sort section](https://dev.wix.com/docs/rest/articles/getting-started/api-query-language.md#the-sort-section).  | validation: maxItems 5
           - name: fieldName | type: string | description: Name of the field to sort by.  | validation: maxLength 512
           - name: order | type: SortOrder | description: Sort order.  
                 - enum: ASC, DESC
 Query fields:
   - field: _id | operators: $eq, $ne, $in, $exists, $gt, $gte, $lt, $lte, $startsWith | sort: ASC, DESC | aggregatable: undefined | searchable: undefined
   - field: contactDetails.contactId | operators: $eq, $ne, $in, $exists, $gt, $gte, $lt, $lte, $startsWith | sort: ASC, DESC | aggregatable: undefined | searchable: undefined
   - field: source.identifiedBy | operators: $eq, $ne, $in, $exists | sort: ASC, DESC | aggregatable: undefined | searchable: undefined
   - field: area._id | operators: $eq, $ne, $in, $exists, $gt, $gte, $lt, $lte, $startsWith | sort: ASC, DESC | aggregatable: undefined | searchable: undefined
   - field: area.locationId | operators: $eq, $ne, $in, $exists, $gt, $gte, $lt, $lte, $startsWith | sort: ASC, DESC | aggregatable: undefined | searchable: undefined
   - field: area.entranceId | operators: $eq, $ne, $in, $exists, $gt, $gte, $lt, $lte, $startsWith | sort: ASC, DESC | aggregatable: undefined | searchable: undefined
   - field: eligibilityDetails.issues | operators: none | sort: ASC, DESC | aggregatable: undefined | searchable: undefined
   - field: planBenefit.poolId | operators: $eq, $ne, $in, $exists, $gt, $gte, $lt, $lte, $startsWith | sort: ASC, DESC | aggregatable: undefined | searchable: undefined
   - field: planBenefit.benefitKey | operators: $eq, $ne, $in, $exists, $gt, $gte, $lt, $lte, $startsWith | sort: ASC, DESC | aggregatable: undefined | searchable: undefined
   - field: planBenefit.type | operators: $eq, $ne, $in, $exists | sort: ASC, DESC | aggregatable: undefined | searchable: undefined
   - field: status | operators: $eq, $ne, $in, $exists | sort: ASC, DESC | aggregatable: undefined | searchable: undefined
   - field: _createdDate | operators: $eq, $ne, $in, $exists, $gt, $gte, $lt, $lte | sort: ASC, DESC | aggregatable: undefined | searchable: undefined
   - field: overriddenBy.wixUserId | operators: $eq, $ne, $in, $exists, $gt, $gte, $lt, $lte, $startsWith | sort: none | aggregatable: undefined | searchable: undefined
 Return type: PROMISE<QueryArrivalsResponse>
  - name: arrivals | type: array<Arrival> | description: Retrieved arrivals.  
     - ONE-OF: 
        - name: planBenefit | type: PlanBenefit | description: The Pricing Plans benefit the entry was taken from: a credit pack or an unlimited plan (`type`). Redeemed in Pricing Plans after the arrival is written, after an override too.  | read-only: true 
           - name: poolId | type: string | description: GUID of the Pricing Plans benefit pool the member holds: the plan or pack they bought. Read-only to Arrivals.  | read-only: true | validation: format GUID
           - name: benefitKey | type: string | description: Key of the benefit inside the pool, as Pricing Plans defines it; a pool can hold several benefits. Read-only to Arrivals.  | read-only: true | validation: minLength 1, maxLength 64
           - name: displayName | type: string | description: Name to display, in the site's language ("10-Class Pack", "Monthly Unlimited"). The owner's own wording; not translated.  | read-only: true | validation: maxLength 200
           - name: type | type: PlanBenefitType | description: Whether the benefit counts entries: a credit pack spends a credit per entry, an unlimited plan counts nothing. Set by the server from the benefit's configuration in Pricing Plans.  | read-only: true 
                 - enum:
                 -     CREDIT: A credit pack: the benefit carries a credit configuration in Pricing Plans, and redeeming an entry spends one credit from its balance ("10-Class Pack").
                 -     UNLIMITED: An unlimited plan: no credit configuration, nothing is counted ("Monthly Unlimited"). The plan's own usage policy (a fixed interval, a rate limit such as three entries a week) may still apply, and Pricing Plans enforces it. Whether the plan is paid once or by subscription is not what this says.
        - name: scheduledEvent | type: ScheduledEvent | description: The scheduled event the person was booked into. Nothing is redeemed for one, and Arrivals doesn't mark its attendance: a business that wants it marked sets up an automation on the "Client arrives" trigger.  | read-only: true 
           - name: eventId | type: string | description: GUID of the scheduled event, as the provider in `appId` knows it. For an event from the Wix Calendar, the GUID in the Wix Calendar Events API.  | read-only: true | validation: minLength 1, maxLength 250
           - name: displayName | type: string | description: Name to display, in the site's language ("Tue 18:00 Reformer"). Not translated.  | read-only: true | validation: maxLength 200
           - name: appId | type: string | description: App GUID of the provider the event came from: the app that owns it on the Wix Calendar, such as Wix Bookings. Scheduled events are read from the Wix Calendar today; a provider of scheduled events of its own may later supply them, and is then identified here.  | read-only: true | validation: format GUID
     - name: _id | type: string | description: Arrival GUID. Returned by Create Arrival; Override Arrival as Granted names it.  | read-only: true | validation: format GUID
     - name: revision | type: string | description: Revision number, which increments by 1 each time the arrival is updated: when a site user overrides a denied arrival (with Override Arrival as Granted, or with a repeat of Create Arrival within 5 seconds that carries `denialOverride`), and when a CRM contact merge moves the arrival to the surviving contact.  | read-only: true | validation: format int64
     - name: _createdDate | type: Date | description: Date and time the arrival was written, right after the person was evaluated at the entrance. For a granted arrival that was not overridden, it is the time the person was let in; for one that a site user overrode afterwards, it is the denial's time, and the override's time is `overriddenDate`; for one let in with `denialOverride` on the Create Arrival call that wrote it, it is the time the arrival was written, a moment after its `overriddenDate`.  | read-only: true 
     - name: _updatedDate | type: Date | description: Date and time the arrival was updated. Equal to `createdDate` until a site user overrides the arrival or a contact merge moves it. For the time of the override itself, read `overriddenDate`, which a later merge does not move.  | read-only: true 
     - name: contactDetails | type: ContactDetails | description: Who arrived: the contact, with their name and picture as Contacts held them when the arrival was written. Always present. On Create Arrival only `contactDetails.contactId` is sent; the server fills in the rest.  
        - name: contactId | type: string | description: GUID of the contact who arrived. The only field of `contactDetails` sent when creating an arrival.  | validation: format GUID
        - name: firstName | type: string | description: The contact's first name at the time of the arrival. Set by the server; personal data. `****` after the contact's personal data is deleted for privacy.  | read-only: true | validation: maxLength 1000
        - name: lastName | type: string | description: The contact's last name at the time of the arrival. Set by the server; personal data. `****` after the contact's personal data is deleted for privacy.  | read-only: true | validation: maxLength 1000
        - name: picture | type: string | description: The contact's profile picture at the time of the arrival, as Contacts held it. Set by the server; personal data. Absent when the contact has none, and absent after the contact's personal data is deleted for privacy.  | read-only: true 
     - name: source | type: ArrivalSource | description: How the arrival came to be, and who created it. Set by the server.  | read-only: true 
        - name: identifiedBy | type: IdentificationMethod | description: How the person was identified: `BY_TOKEN` when a pass token was presented and the arrival was written by Create Arrival By Credential, `BY_CONTACT` when the arrival was written by contact GUID with nothing presented. Who wrote the arrival (a Wix user, or an app such as a reader at an entrance) is `createdBy`.  
             - enum:
             -     BY_TOKEN: A pass token was presented at the entrance: a QR code scanned by a site collaborator in a scanner app, or by a reader; `createdBy` says which. The arrival was written by [Create Arrival By Credential](https://dev.wix.com/docs/api-reference/business-solutions/bookings/arrivals/arrival/create-arrival-by-credential.md) with `token`.
             -     BY_CONTACT: Written by contact ID with nothing presented (from the contact card in the dashboard, or by an app), even when the contact holds a credential.
        - name: createdBy | type: IdentificationData | description: Who created the arrival, from the call identity: a Wix user (`wixUserId`), such as a site collaborator in a scanner app or an owner on the contact card, or an app (`appId`), such as a reader at an entrance or a partner app. This, not `identifiedBy`, is what tells a Wix user from an app, such as a reader or a partner app. Only `wixUserId` or `appId` is ever set; `anonymousVisitorId` and `memberId` never appear on an arrival, since members and visitors can't create arrivals. Who let the person in against a denial is `overriddenBy`, not this field.  
           - ONE-OF: 
              - name: anonymousVisitorId | type: string | description: GUID of a site visitor who hasn't logged in to the site.  | validation: format GUID
              - name: memberId | type: string | description: GUID of a site visitor who has logged in to the site.  | validation: format GUID
              - name: wixUserId | type: string | description: GUID of a Wix user. For example, the site owner or a [site collaborator](https://support.wix.com/en/article/inviting-people-to-contribute-to-your-site).  | validation: format GUID
              - name: appId | type: string | description: GUID of an app.  | validation: format GUID
     - name: area | type: AreaInfo | description: The area the person entered and the entrance they came in through, with the area's name and location and the entrance's name as they were at the time of the arrival. On Create Arrival only `area.entranceId` is sent; the server finds the area the entrance belongs to and fills in the rest.  
        - name: _id | type: string | description: GUID of the area. Set by the server: the area the entrance belongs to.  | read-only: true | validation: format GUID
        - name: locationId | type: string | description: GUID of the business location the area belonged to at the time of the arrival, from the Locations API. Kept on the record so history survives an area moving to another location.  | read-only: true | validation: format GUID
        - name: name | type: string | description: Name of the area at the time of the arrival, kept on the record so history still reads right after the area is renamed.  | read-only: true | validation: minLength 1, maxLength 100
        - name: entranceId | type: string | description: GUID of the entrance the person came in through, one of an area's `entrances[].id`. The one field of `area` sent when creating an arrival.  | validation: format GUID
        - name: entranceName | type: string | description: Name of the entrance at the time of the arrival, kept on the record so history still reads right after the entrance is renamed or removed.  | read-only: true | validation: minLength 1, maxLength 100
     - name: eligibilityDetails | type: EligibilityDetails | description: What the engine found, from which `status` was derived: the issues of the entry as a whole, the intake forms the person is missing, and every plan benefit and scheduled event it found for the area, each with its own issue. Set by the server at creation and never changed afterwards: an override keeps it, so its `issues` hold what was overridden. Returned only to callers with the `SCOPE.ARRIVALS.READ-ELIGIBILITY-DETAILS` permission scope, since it says why a person was not eligible; filtering on `eligibilityDetails.issues` requires the same scope. Every response that carries an arrival leaves it out for other callers, Create Arrival and Create Arrival By Credential included: an app without the permission, such as a reader at an entrance, gets `status` and not the reason.  | read-only: true 
        - name: issues | type: array<EntryIssue> | description: The issues of the entry as a whole. The issues decide the status the evaluation gives: `GRANTED` when there are none, or only `INTAKE_FORM_MISSING` for forms that do not block entry; `DENIED` otherwise. When a site user lets the person in (afterwards with Override Arrival as Granted, or beforehand with `denialOverride` on Create Arrival), the status is `GRANTED` whatever the issues, and the issues show what was overridden. On an arrival, `PRICING_PLANS_UNAVAILABLE` and `CONTACTS_UNAVAILABLE` are found only that way, with `denialOverride`, since otherwise Create Arrival fails with `UNAVAILABLE`; Check Eligibility reports them without failing. A `DENIED` arrival always has at least one. Empty when nothing stood in the way.  | validation: maxItems 3
             - enum:
             -     NO_ELIGIBLE_GRANT: No grant the person holds admits them into this area now. A grant is what can grant entry: a plan benefit (`planBenefits`) or a scheduled event they are booked on (`scheduledEvents`), the same two kinds an arrival records in `planBenefit` or `scheduledEvent` once granted. Either nothing was found (`planBenefits` and `scheduledEvents` are empty), or everything found has an issue of its own, which says why. A contact whose site member's status (`memberInfo.status` in Contacts) is `BLOCKED`, `DELETED` or `OFFLINE` holds no plans here, so it finds none. Also reported when a credit pack would admit but the person is booked on an event here and now that still waits for approval: no credit is spent while the booking may be approved moments later (the event carries `PENDING_CONFIRMATION`). Declines at creation; site collaborators override, or sell a plan, approve the booking or renew the plan and create a new arrival. Not reported when Pricing Plans or Contacts did not answer: `PRICING_PLANS_UNAVAILABLE` or `CONTACTS_UNAVAILABLE` takes its place.
             -     INTAKE_FORM_MISSING: Not reported yet, since intake forms aren't checked at entry. Once they are, it means the person has no valid submission for at least one intake form the area's policy requires: never submitted, expired, canceled, or pending approval. The forms are listed in `missingIntakeForms`. Declines at creation when a missing form has `blocksEntry`; otherwise grants, with the issue kept on the arrival so site collaborators can chase the paperwork.
             -     RECENT_ENTRY: The person was already granted entry into this area within the last 15 minutes and a credit would be spent again: a retried scan, a re-entry, or a guest on the same credential. The earlier entry counts whatever granted it: a credit, an unlimited plan, a scheduled event or an override, and the 15 minutes count from that arrival's `createdDate`, or for an overridden arrival from its `overriddenDate`, when a site user let the person in. Declines at creation; the override spends a credit. Reported only when this entry would spend a credit: not when an unlimited plan or a scheduled event admits now.
             -     PRICING_PLANS_UNAVAILABLE: Pricing Plans didn't answer (it couldn't be reached, didn't answer in time, or failed on its side; any of these is an outage), so plan benefits were not checked. On an arrival, only on one let in by Create Arrival with `denialOverride`, since without a site user's decision the call fails with `UNAVAILABLE` instead and no denied arrival is written; Check Eligibility reports it without failing; Override Arrival as Granted does not call Pricing Plans. `planBenefits` is empty, no `planBenefit` is recorded and nothing is redeemed; scheduled events and intake forms are still evaluated. Reported instead of `NO_ELIGIBLE_GRANT`, never with it: plan benefits were not checked, so the person may hold one that admits. An issue a scheduled event has of its own stays on that event in `eligibilityDetails`.
             -     CONTACTS_UNAVAILABLE: Contacts didn't answer (it couldn't be reached, didn't answer in time, or failed on its side; any of these is an outage), so the person's member is unknown and plan benefits were not checked. On an arrival, only on one let in by Create Arrival with `denialOverride`, since without a site user's decision the call fails with `UNAVAILABLE` instead and no denied arrival is written; Check Eligibility reports it without failing. `planBenefits` is empty, no `planBenefit` is recorded, nothing is redeemed, and `contactDetails` has the contact ID alone, with no name or picture; scheduled events, read by contact, are still evaluated. Reported instead of `NO_ELIGIBLE_GRANT` and `PRICING_PLANS_UNAVAILABLE`, never with them: Pricing Plans is not read without the member.
        - name: missingIntakeForms | type: array<MissingIntakeForm> | description: Every intake form the area's policy requires and the person has no valid submission for, with its `blocksEntry`, so an app can point site collaborators to the right form. Empty unless `issues` contains `INTAKE_FORM_MISSING`, so always empty for now: intake forms aren't checked at entry yet.  | validation: maxItems 20
           - name: formId | type: string | description: GUID of the intake form, from the Intake Forms API, as listed in the area's policy.  | validation: format GUID
           - name: blocksEntry | type: boolean | description: Whether this missing form blocks entry, as configured on the area's policy (`policy.intakeForms[].blocksEntry` in the Areas API). `false`: the arrival is granted and site collaborators are warned. `true`: the arrival is denied until the form is submitted; site collaborators can still override.  
        - name: planBenefits | type: array<PlanBenefitEligibility> | description: The person's Pricing Plans benefits allowed into this area, each a `planBenefit` with its own `issues`: empty means the benefit admits. Listed on a `DENIED` arrival too, admitting ones included, so an override can take one later. The grant picks one by the rule on the arrival's `planBenefit` and records it there. Listed in the order of that rule, so the first is the one a grant takes; at most 20 are listed, the first 20 in that order. Empty when the person holds no benefit for this area, and when the status of the contact's site member (`memberInfo.status` in Contacts) is `BLOCKED`, `DELETED` or `OFFLINE`, since such a member holds no plans here.  | validation: maxItems 20
           - name: planBenefit | type: PlanBenefit | description: The benefit found, as `planBenefit` records it on an arrival.  | read-only: true 
           - name: issues | type: array<PlanBenefitIssue> | description: Why the benefit does not admit, in Pricing Plans' own words where it has one. Empty: the benefit admits. At most one is reported, since Pricing Plans gives one reason.  | read-only: true | validation: maxItems 1
                 - enum:
                 -     PLAN_NOT_ACTIVE: The benefit's plan isn't active at the time of the entry (ended, canceled, paused, not started yet, or for a moment while it's being renewed), as Pricing Plans reports. Site collaborators override, or renew the plan and create a new arrival.
                 -     NOT_ENOUGH_BALANCE: A credit pack with no credits left, as Pricing Plans reports. Site collaborators override, or sell credits and create a new arrival.
                 -     OUTSIDE_ACCESS_HOURS: The plan's usage policy does not allow entry at this hour or on this day, or another rule of the plan refuses entry, as Pricing Plans reports. A used-up limit on its own is `USAGE_LIMIT_REACHED`.
                 -     USAGE_LIMIT_REACHED: The plan's usage policy limits how often it can be used, such as three entries a week, and that limit is used up for the current period, as Pricing Plans reports. Site collaborators override, or the client comes back in the next period.
        - name: scheduledEvents | type: array<ScheduledEventEligibility> | description: The scheduled events the person is booked on at this area's location inside the area's entry window, each with its own `issues`: empty means the event admits. Listed on a `DENIED` arrival too, admitting ones included, so an override can take one later. Check Eligibility with a `scheduledEventSearchWindow` also lists the events that start inside that window, with `OUTSIDE_ENTRY_WINDOW`; Create Arrival never does. At most 20 are listed: the events inside the area's window first, then the others by start time, earliest first. Always empty while the area's `scheduledEventsPolicy.entryGrantingAppIds` is empty.  | validation: maxItems 20
           - name: scheduledEvent | type: ScheduledEvent | description: The event found, as `scheduledEvent` records it on an arrival.  | read-only: true 
           - name: issues | type: array<ScheduledEventIssue> | description: Why the event does not admit. Empty: the event admits. At most one is reported: when both apply, `OUTSIDE_ENTRY_WINDOW` wins over `PENDING_CONFIRMATION`, since approving the booking would not help outside the window.  | read-only: true | validation: maxItems 1
                 - enum:
                 -     PENDING_CONFIRMATION: The person is booked on the event here and now, but the booking still waits for the business's approval. Only an appointment can be pending. A credit pack is not spent instead (`NO_ELIGIBLE_GRANT`), since the booking may be approved moments later; an unlimited plan allowed into the area still admits. Site collaborators approve the booking and create a new arrival, or override.
                 -     OUTSIDE_ENTRY_WINDOW: The person is booked on the event, but now is outside the area's entry window for it (`policy.scheduledEventsPolicy.entryWindow` in the Areas API). Only on an event listed by a Check Eligibility with `scheduledEventSearchWindow`; never on an arrival, since Create Arrival does not find events outside the area's window.
     - name: status | type: Status | description: Whether access was given. Set by the server: by Create Arrival, from the issues (`GRANTED` despite them when the call carries `denialOverride`), and moved from `DENIED` to `GRANTED` by Override Arrival as Granted. Never sent by a caller.  | read-only: true 
         - enum:
         -     GRANTED: Access was given: the person entered. Either the engine found no issue that blocks entry, or a site user overrode a denial, afterwards with Override Arrival as Granted or on Create Arrival with `denialOverride`; `eligibilityDetails.issues` then holds what was overridden.
         -     DENIED: Access was not given: the engine found an issue that declines (see `EntryIssue`), and no site user has overridden it. A site user may still override with Override Arrival as Granted, which moves the status to `GRANTED`.
     - name: overrideReason | type: string | description: Why a site user let the person in against the issues, in their own words. Optional; written by Override Arrival as Granted, or from `denialOverride.reason` when Create Arrival let the person in despite a denial, so it can be present only on a `GRANTED` arrival with issues; either way the actor is `overriddenBy`. Free text that may describe the person, so it is personal data: `****` after the contact's personal data is deleted for privacy. It is returned only to callers with the `SCOPE.ARRIVALS.READ-ELIGIBILITY-DETAILS` permission scope.  | read-only: true | validation: maxLength 500
     - name: overriddenBy | type: IdentificationData | description: Who let the person in against a denial: the caller of Override Arrival as Granted, or of Create Arrival with `denialOverride`. Set by the server; present only on an arrival a site user let in against a denial, absent on every other arrival. Always a Wix user (`wixUserId`), since only site users may override. Who wrote the arrival is `source.createdBy`; the two can differ.  | read-only: true 
     - name: overriddenDate | type: Date | description: Date and time a site user let the person in against a denial, set once with `overriddenBy`: when Override Arrival as Granted granted the arrival, or the time Create Arrival evaluated the person when it let them in with `denialOverride` on the call that wrote it: a moment before that arrival's `createdDate`, which is stamped when the arrival is written. Set by the server; absent on every arrival no site user overrode. A later contact merge moves `updatedDate` but never this.  | read-only: true 
  - name: pagingMetadata | type: CursorPagingMetadata | description: Paging metadata.  
     - name: count | type: integer | description: Number of items returned in current page.  | validation: format int32
     - name: cursors | type: Cursors | description: Cursor strings that point to the next page, previous page, or both.  
        - name: next | type: string | description: Cursor string pointing to the next page in the list of results.  | validation: maxLength 16000
        - name: prev | type: string | description: Cursor pointing to the previous page in the list of results.  | validation: maxLength 16000
     - name: hasNext | type: boolean | description: Whether there are more pages to retrieve following the current page.  + `true`: Another page of results can be retrieved. + `false`: This is the last page.  

 Possible Errors:
   HTTP Code: 400 | Status Code: INVALID_ARGUMENT | Application Code: CREATED_DATE_LOWER_BOUND_REQUIRED | Description: The filter or sort uses a field with no index (`status`, `source.identifiedBy`, `eligibilityDetails.issues`, `planBenefit.poolId`, `planBenefit.benefitKey`, `planBenefit.type` or `overriddenBy.wixUserId`) without a lower bound on `createdDate` (`$gt` or `$gte`) no more than 400 days ago.


```

### Examples

### List today's denied arrivals at a location
A filter on status needs a createdDate lower bound no more than 400 days ago.

```javascript
import { arrivals } from "@wix/arrivals";

async function queryArrivals() {
  const response = await arrivals.queryArrivals({
    filter: {
      "area.locationId": "0b3fa0a1-6f0a-4a5e-9e64-2b7a4a6f0c11",
      status: "DENIED",
      _createdDate: { $gte: "2026-09-09T00:00:00Z" },
    },
    sort: [{ fieldName: "_createdDate", order: "DESC" }],
    cursorPaging: { limit: 50 },
  });

  return response;
}

/* Promise resolves to:
 * {
 *   "arrivals": [
 *     {
 *       "_id": "4b5c6d7e-8f9a-4b0c-9d1e-2f3a4b5c6d7e",
 *       "revision": "1",
 *       "_createdDate": "2026-09-09T16:48:19.550Z",
 *       "_updatedDate": "2026-09-09T16:48:19.550Z",
 *       "contactDetails": {
 *         "contactId": "7f8a9b0c-1d2e-4f3a-8b4c-5d6e7f8a9b0c",
 *         "firstName": "Noa",
 *         "lastName": "Levi"
 *       },
 *       "source": {
 *         "identifiedBy": "BY_CONTACT",
 *         "createdBy": { "wixUserId": "4d5e6f7a-8b9c-4d0e-9f1a-2b3c4d5e6f7a" }
 *       },
 *       "area": {
 *         "_id": "8046df3c-7575-4098-a5ab-c91ad8f33c47",
 *         "name": "Main floor",
 *         "locationId": "0b3fa0a1-6f0a-4a5e-9e64-2b7a4a6f0c11",
 *         "entranceId": "1f6d2c3a-9b8e-4d7c-a6f5-0e1d2c3b4a59",
 *         "entranceName": "Front entrance"
 *       },
 *       "eligibilityDetails": { "issues": ["NO_ELIGIBLE_GRANT"] },
 *       "status": "DENIED"
 *     }
 *   ],
 *   "pagingMetadata": {
 *     "count": 1,
 *     "hasNext": false
 *   }
 * }
 */

```

### queryArrivals (self-managed)
Self-managed SDK calls require you to [create a client](https://dev.wix.com/docs/sdk/articles/work-with-the-sdk/about-the-wix-client.md).

```javascript
import { createClient } from '@wix/sdk';
import { arrivals } from '@wix/arrivals';
// Import the auth strategy for the relevant access type
// Import the relevant host module if needed

const myWixClient = createClient ({
  modules: { arrivals },
  // Include the auth strategy and host as relevant
});


async function queryArrivals(query) {
  const response = await myWixClient.arrivals.queryArrivals(query);
};
```

---