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

# Search Nexus Statements

> Searches system for Nexus statements. At least one search parameter is required.

> Note: Results are returned in page sizes of 500 records, use the page parameter to paginate through full result set.

_Response Body Structure_

| Path | Type | Description |
| --- | --- | --- |
| `[].uuid` | `UUID` | EnergyWatch universally unique identifier |
| `[].status` | `Enum` | Available values : ERROR, NEW, PROCESSED, RETRIEVED, SYSTEM_UPDATED, UPDATED |
| `[].ww_account_id` | `Integer` | EnergyWatch account identifier |
| `[].ww_statement_id` | `Integer` | EnergyWatch statement identifier |
| `[].ww_client_id` | `Integer` | EnergyWatch client node identifier |
| `[].ww_control_code` | `String` | EnergyWatch Control Code identifier for PDFs |
| `[].status_message` | `String` | Status message |
| `[].nexus_json` | `Nexus Statement Model` | The statement's raw body |



## OpenAPI

````yaml /tango_watchwire/integrations/guides/watchwire-api.yaml get /statement/nexus
openapi: 3.1.0
info:
  title: WatchWire API
  version: 1.0.0
  description: >-
    The WatchWire Platform has APIs that allow you to access your data
    programmatically. There are several APIs designed for the modules in the
    WatchWire platform including - Invoice Data, Real-Time, Accounts Payable,
    and Measurement & Verification. All are highly scalable, and secure APIs
    that communicate over HTTPS RESTful protocols with JSON based documents.


    > **Note**: Not all WatchWire modules are available as an API.


    # Authentication


    You need credentials to access the APIs - it is the same credentials as your
    WatchWire login. The `/authenticate` will return a Token that needs to be
    included in the header of every subsequent request. The token renews with
    each request and expires after 60 minutes of inactivity (at which point you
    will need to re-authenticate and get a new token).


    > Please contact the WatchWire team for any questions or request for API
    credential access.


    # Error Codes


    There will be various error codes specific to the API you are using, but
    generally follows these principles:


    *   `Unauthorized` - *you are unauthenticated or unauthorized to request
    actions on an asset*

    *   `Asset doesn't exist` - *the item you are querying for doesn't exist*

    *   `Server error`\- *general exception raised in our application code*
        

    # Rate limit


    Rate limited to 10 transactions per meter / second
servers:
  - url: https://auth.replace-me.example.com
    description: Authentication service (Postman variable {{ww-api-baseurl}})
  - url: https://realtime.replace-me.example.com
    description: RealTime API (Postman variable {{gateway-realtime-api}})
  - url: https://ap.replace-me.example.com
    description: Accounts Payable API (Postman variable {{gateway-ap-api}})
  - url: https://invoice.replace-me.example.com
    description: Invoice API (Postman variable {{portal-api-baseurl}})
  - url: https://mv.replace-me.example.com
    description: Measurement & Verification API (Postman variable {{invoice-api}})
security:
  - BearerAuth: []
tags:
  - name: Authentication
  - name: RealTime API - Custom Meter
  - name: RealTime API - Meter Readings
  - name: RealTime API - Meter Readings Aggregations
  - name: RealTime API - Meter Readings Batch Operations
  - name: RealTime API - Obvius Meter Readings
  - name: Accounts Payable API - Audit Statements
  - name: Accounts Payable API - Nexus Statements
  - name: Accounts Payable API - Standard Statements
  - name: Accounts Payable API - Statement PDFs
  - name: Invoice API - Reference IDs
  - name: Invoice API - Invoice
  - name: Measurement & Verification API - M&V
paths:
  /statement/nexus:
    get:
      tags:
        - Accounts Payable API - Nexus Statements
      summary: Search Nexus Statements
      description: >-
        Searches system for Nexus statements. At least one search parameter is
        required.


        > Note: Results are returned in page sizes of 500 records, use the page
        parameter to paginate through full result set.


        _Response Body Structure_


        | Path | Type | Description |

        | --- | --- | --- |

        | `[].uuid` | `UUID` | EnergyWatch universally unique identifier |

        | `[].status` | `Enum` | Available values : ERROR, NEW, PROCESSED,
        RETRIEVED, SYSTEM_UPDATED, UPDATED |

        | `[].ww_account_id` | `Integer` | EnergyWatch account identifier |

        | `[].ww_statement_id` | `Integer` | EnergyWatch statement identifier |

        | `[].ww_client_id` | `Integer` | EnergyWatch client node identifier |

        | `[].ww_control_code` | `String` | EnergyWatch Control Code identifier
        for PDFs |

        | `[].status_message` | `String` | Status message |

        | `[].nexus_json` | `Nexus Statement Model` | The statement's raw body |
      operationId: searchNexusStatements
      parameters:
        - name: accountId
          in: query
          required: false
          schema:
            type: integer
          description: EnergyWatch account identifier
        - name: clientId
          in: query
          required: false
          schema:
            type: integer
          description: EnergyWatch client node identifier
        - name: controlAmount
          in: query
          required: false
          schema:
            type: number
          description: The invoice total
        - name: controlCode
          in: query
          required: false
          schema:
            type: string
          description: EnergyWatch Control Code identifier for PDFs
        - name: integrationPackageName
          in: query
          required: false
          schema:
            type: string
          description: Name of the integration package
        - name: invoiceBudgetOverageNote
          in: query
          required: false
          schema:
            type: string
          description: Budget overage notes
        - name: invoiceDateTm
          in: query
          required: false
          schema:
            type: string
            format: date
          description: An invoice date
        - name: invoiceDueDate
          in: query
          required: false
          schema:
            type: string
            format: date
          description: A due date
        - name: invoiceNote
          in: query
          required: false
          schema:
            type: string
          description: Notes
        - name: invoicePeriod
          in: query
          required: false
          schema:
            type: string
            format: date
          description: Period for the invoice in (where day is always 01)
        - name: invoiceRef
          in: query
          required: false
          schema:
            type: string
          description: The invoice number
        - name: propertyIdAlt
          in: query
          required: false
          schema:
            type: string
          description: Property code
        - name: shipping
          in: query
          required: false
          schema:
            type: number
          description: The total shipping amount for the invoice
        - name: statementId
          in: query
          required: false
          schema:
            type: integer
          description: EnergyWatch statement identifier
        - name: status
          in: query
          required: false
          schema:
            type: string
            enum:
              - ERROR
              - NEW
              - PROCESSED
              - RETRIEVED
              - SYSTEM_UPDATED
              - UPDATED
          description: >-
            Available values : ERROR, NEW, PROCESSED, RETRIEVED, SYSTEM_UPDATED,
            UPDATED
        - name: statusMessage
          in: query
          required: false
          schema:
            type: string
          description: Status message
        - name: tax
          in: query
          required: false
          schema:
            type: number
          description: The total tax amount for the invoice
        - name: universalField1
          in: query
          required: false
          schema:
            type: string
          description: Value for a custom field
        - name: universalField2
          in: query
          required: false
          schema:
            type: string
          description: Value for a custom field
        - name: universalField3
          in: query
          required: false
          schema:
            type: string
          description: Value for a custom field
        - name: universalField4
          in: query
          required: false
          schema:
            type: string
          description: Value for a custom field
        - name: universalField5
          in: query
          required: false
          schema:
            type: string
          description: Value for a custom field
        - name: universalField6
          in: query
          required: false
          schema:
            type: string
          description: Value for a custom field
        - name: universalField7
          in: query
          required: false
          schema:
            type: string
          description: Value for a custom field
        - name: universalField8
          in: query
          required: false
          schema:
            type: string
          description: Value for a custom field
        - name: userProfileUsername
          in: query
          required: false
          schema:
            type: string
          description: >-
            The username of the user who will be considered the creator of the
            invoice
        - name: uuid
          in: query
          required: false
          schema:
            type: string
            format: uuid
          description: Energywatch universally unique identifier
        - name: vendorIdAlt
          in: query
          required: false
          schema:
            type: string
          description: Vendor code
        - name: orderBy
          in: query
          required: false
          schema:
            type: string
          description: >-
            (Optional) order by clause when searching statements, useful during
            paginated requests
        - name: page
          in: query
          required: false
          schema:
            type: integer
            minimum: 1
          description: >-
            (Optional) used to paginate through large resultset, NOTE: results
            come back in page sizes of 500 records
      responses:
        '200':
          description: Successful response
          content:
            application/json:
              schema:
                type: array
                items:
                  type: object
                  properties:
                    uuid:
                      type: string
                    status:
                      type: string
                    ww_account_id:
                      type: integer
                    ww_statement_id:
                      type: integer
                    ww_client_id:
                      type: integer
                    ww_control_code:
                      type: string
                    status_message:
                      type: string
                    nexus_json:
                      type: object
                      properties:
                        tax:
                          type: integer
                        shipping:
                          type: integer
                        priority:
                          type: string
                        lines:
                          type: array
                          items:
                            type: object
                            properties:
                              line_item_uuid:
                                type: string
                              invoiceitem_quantity:
                                type: integer
                              invoiceitem_unitprice:
                                type: integer
                              glaccount_number:
                                type: string
                              unit_id_alt:
                                type: string
                              utilityusagetype_name:
                                type: string
                              utilityaccount_accountnumber:
                                type: string
                              invoiceitem_description:
                                type: string
                              property_id_alt:
                                type: string
                              invoiceitem_taxflag:
                                type: string
                              universal_field1:
                                type: string
                              universal_field2:
                                type: string
                              universal_field3:
                                type: string
                              universal_field4:
                                type: string
                              universal_field5:
                                type: string
                              universal_field6:
                                type: string
                              universal_field7:
                                type: string
                              universal_field8:
                                type: string
                        integration_package_name:
                          type: string
                        property_id_alt:
                          type: string
                        vendor_id_alt:
                          type: string
                        userprofile_username:
                          type: string
                        invoice_datetm:
                          type: string
                        invoice_ref:
                          type: string
                        invoice_duedate:
                          type: string
                        invoice_period:
                          type: string
                        control_amount:
                          type: integer
                        remit_advice:
                          type: integer
                        invoice_private:
                          type: integer
                        currency_code:
                          type: string
                        country_code:
                          type: string
                        invoice_cycle_from:
                          type: string
                        invoice_cycle_to:
                          type: string
                        invoice_note:
                          type: string
                        invoice_budgetoverage_note:
                          type: string
                        universal_field1:
                          type: string
                        universal_field2:
                          type: string
                        universal_field3:
                          type: string
                        universal_field4:
                          type: string
                        universal_field5:
                          type: string
                        universal_field6:
                          type: string
                        universal_field7:
                          type: string
                        universal_field8:
                          type: string
                        invoicepayment_type:
                          type: string
              example:
                - uuid: 83c2d4bf-febc-44bd-9a97-fdb387f4199b
                  status: NEW
                  ww_account_id: 0
                  ww_statement_id: 0
                  ww_client_id: 0
                  ww_control_code: string
                  status_message: string
                  nexus_json:
                    tax: 0
                    shipping: 0
                    priority: string
                    lines:
                      - line_item_uuid: b9cc5c2e-53d2-47fd-9521-e1f120370f20
                        invoiceitem_quantity: 0
                        invoiceitem_unitprice: 0
                        glaccount_number: string
                        unit_id_alt: string
                        utilityusagetype_name: string
                        utilityaccount_accountnumber: string
                        invoiceitem_description: string
                        property_id_alt: string
                        invoiceitem_taxflag: 'N'
                        universal_field1: string
                        universal_field2: string
                        universal_field3: string
                        universal_field4: string
                        universal_field5: string
                        universal_field6: string
                        universal_field7: string
                        universal_field8: string
                    integration_package_name: JDE
                    property_id_alt: '12345'
                    vendor_id_alt: '12345'
                    userprofile_username: EWServices
                    invoice_datetm: '2020-12-10'
                    invoice_ref: string
                    invoice_duedate: '2020-12-10'
                    invoice_period: '2020-12-10'
                    control_amount: 0
                    remit_advice: 0
                    invoice_private: 0
                    currency_code: string
                    country_code: string
                    invoice_cycle_from: '2020-12-10'
                    invoice_cycle_to: '2020-12-10'
                    invoice_note: string
                    invoice_budgetoverage_note: string
                    universal_field1: string
                    universal_field2: string
                    universal_field3: string
                    universal_field4: string
                    universal_field5: string
                    universal_field6: string
                    universal_field7: string
                    universal_field8: string
                    invoicepayment_type: string
        '401':
          description: Unauthorized - missing, invalid or expired token
      security:
        - BearerAuth: []
      servers:
        - url: https://ap.replace-me.example.com
          description: Accounts Payable API (Postman variable {{gateway-ap-api}})
components:
  securitySchemes:
    BearerAuth:
      type: http
      scheme: bearer
      description: >-
        Token returned by `POST /authenticate`. Expires after 60 minutes of
        inactivity.

````