# List order approvals

Returns all Approvals associated with the Order.

Endpoint: GET /orders/{direction}/{orderID}/approvals
Version: 1.0.448.36393
Security: OAuth2

## Path parameters:

  - `direction` (string, required)
    Direction of the order, from the current user's perspective.
    Enum: "Incoming", "Outgoing", "All"

  - `orderID` (string, required)
    ID of the order.

## Query parameters:

  - `search` (string)
    Word or phrase to search for.

  - `searchOn` (array)
    Comma-delimited list of fields to search on.
    Enum: "ApprovalRuleID", "ApprovingGroupID", "Approver", "Comments"

  - `sortBy` (array)
    Comma-delimited list of fields to sort by.
    Enum: "DateCreated", "AllowResubmit", "ApprovalRuleID", "ApprovingGroupID", "Status", "DateCompleted", "Approver", "!DateCreated", "!AllowResubmit", "!ApprovalRuleID", "!ApprovingGroupID", "!Status", "!DateCompleted", "!Approver"

  - `page` (integer)
    Page of results to return. When paginating through many items (> page 30), we recommend the "Last ID" method, as outlined in the Advanced Querying documentation.

  - `pageSize` (integer)
    Number of results to return per page.

  - `filters` (object)
    An object or dictionary representing key/value pairs to apply as filters. Valid keys are top-level properties of the returned model or 'xp.???'

## Response 200 fields (application/json):

  - `Items` (array)
    Example: [{"AllowResubmit":false,"ApprovalRuleID":"","ApprovingGroupID":"","Status":"Pending","DateCreated":"2018-01-01T00:00:00-06:00","DateCompleted":"2018-01-01T00:00:00-06:00","Approver":{"FailedLoginAttempts":0,"ID":"","CompanyID":"","Username":"","Password":"","FirstName":"","LastName":"","Email":"","Phone":"","TermsAccepted":"2018-01-01T00:00:00-06:00","Active":false,"xp":{},"AvailableRoles":[""],"Locale":{"ID":"","OwnerID":"","Currency":"","Language":""},"DateCreated":"2018-01-01T00:00:00-06:00","LastActive":"2018-01-01T00:00:00-06:00","PasswordLastSetDate":"2018-01-01T00:00:00-06:00"},"Comments":""}]

  - `Items.AllowResubmit` (boolean)
    If true, the submitting user will be able to modify the order and resubmit for approval.

  - `Items.ApprovalRuleID` (string)

  - `Items.ApprovingGroupID` (string)

  - `Items.Status` (string)
    Enum: "Pending", "Approved", "Declined"

  - `Items.DateCreated` (string)
    Example: "2018-01-01T00:00:00-06:00"

  - `Items.DateCompleted` (string)
    Example: "2018-01-01T00:00:00-06:00"

  - `Items.Approver` (object)
    Example: {"FailedLoginAttempts":0,"ID":"","CompanyID":"","Username":"","Password":"","FirstName":"","LastName":"","Email":"","Phone":"","TermsAccepted":"2018-01-01T00:00:00-06:00","Active":false,"xp":{},"AvailableRoles":[""],"Locale":{"ID":"","OwnerID":"","Currency":"","Language":""},"DateCreated":"2018-01-01T00:00:00-06:00","LastActive":"2018-01-01T00:00:00-06:00","PasswordLastSetDate":"2018-01-01T00:00:00-06:00"}

  - `Items.Approver.FailedLoginAttempts` (integer)
    Number of times the user failed authentication due to incorrect password since last successful attempt, or since being unlocked.

  - `Items.Approver.ID` (string)

  - `Items.Approver.CompanyID` (string)

  - `Items.Approver.Username` (string)
    Must be unique across all organizations.

  - `Items.Approver.Password` (string)

  - `Items.Approver.FirstName` (string)

  - `Items.Approver.LastName` (string)

  - `Items.Approver.Email` (string)

  - `Items.Approver.Phone` (string)

  - `Items.Approver.TermsAccepted` (string)
    Example: "2018-01-01T00:00:00-06:00"

  - `Items.Approver.Active` (boolean)
    If false, authentication is prohibited.

  - `Items.Approver.xp` (object)
    Example: {}

  - `Items.Approver.AvailableRoles` (array)
    List of roles currently available to the user via all security profile assignments.
    Example: [""]

  - `Items.Approver.Locale` (object)
    Most specific locale assigned to the user, if any.
    Example: {"ID":"","OwnerID":"","Currency":"","Language":""}

  - `Items.Approver.Locale.ID` (string)

  - `Items.Approver.Locale.OwnerID` (string)
    ID of the organization that owns the Locale. Only the marketplace owner can override the OwnerID on create.

  - `Items.Approver.Locale.Currency` (string)
    We recommend using ISO-4217 currency codes for compatibility with tax and payment processors.

  - `Items.Approver.Locale.Language` (string)
    We recommend using ISO-639 language code - ISO-3166 Country code (e.g. en-US).

  - `Items.Approver.DateCreated` (string)
    Example: "2018-01-01T00:00:00-06:00"

  - `Items.Approver.LastActive` (string)
    Accurate within a few minutes. Includes impersonation activity.
    Example: "2018-01-01T00:00:00-06:00"

  - `Items.Approver.PasswordLastSetDate` (string)
    Can be used in conjunction with SecurityProfile.PasswordConfig to enforce password reset schedules.
    Example: "2018-01-01T00:00:00-06:00"

  - `Items.Comments` (string)

  - `Meta` (object)

  - `Meta.Page` (integer)

  - `Meta.PageSize` (integer)

  - `Meta.TotalCount` (integer)

  - `Meta.TotalPages` (integer)

  - `Meta.ItemRange` (array)

  - `Meta.NextPageKey` (string)

## Response 4XX fields (application/json):

  - `StatusCode` (integer)
    Example: "404"

  - `ErrorCode` (string)
    Example: "NotFoundError"

  - `Message` (string)
    Example: "Object not found"

  - `Data` (object)
    Example: {"ObjectType":"","ObjectID":""}


