# List parties

Source: https://amanucci.com/docs/developers/api/parties/listParties

## GET /v1/entities/{entityId}/parties

List parties

This entity's LIVE parties in the walk `order` names, PAGED BY CURSOR (rule 5): a merged party is absent here (it is no longer offered) and reachable by id. Each row carries where the entity and the party stand at the business day: what it owes and how late, what the entity owes it, the rail an invoice would go by and its latest document. `role` is the Contacts view, read from the documents; `q` searches.

Operation ID: `listParties`

### Parameters

```json
[
  {
    "schema": {
      "type": "string",
      "format": "uuid"
    },
    "required": true,
    "name": "entityId",
    "in": "path"
  },
  {
    "schema": {
      "type": "string",
      "description": "An opaque position, taken verbatim from a previous response's `nextCursor`. Never construct one: its encoding is an implementation detail and may change within `/v1` (rule 6 governs FIELDS, not the contents of an opaque token)."
    },
    "required": false,
    "description": "An opaque position, taken verbatim from a previous response's `nextCursor`. Never construct one: its encoding is an implementation detail and may change within `/v1` (rule 6 governs FIELDS, not the contents of an opaque token).",
    "name": "cursor",
    "in": "query"
  },
  {
    "schema": {
      "type": "integer",
      "minimum": 1,
      "maximum": 200,
      "default": 200,
      "description": "How many rows at most. The hard ceiling is 200; a larger value is refused with 422, never silently reduced."
    },
    "required": false,
    "description": "How many rows at most. The hard ceiling is 200; a larger value is refused with 422, never silently reduced.",
    "name": "limit",
    "in": "query"
  },
  {
    "schema": {
      "type": "string",
      "enum": [
        "id",
        "name.asc",
        "name.desc",
        "owed.desc",
        "owed.asc",
        "payable.desc",
        "payable.asc",
        "last.desc",
        "last.asc"
      ],
      "default": "id",
      "description": "The walk. `id` (the default): the order parties were written in, the walk it always had. `name.asc` / `.desc` by name, case folded first; `owed.desc` / `.asc` what the party owes (`openReceivable`); `payable.desc` / `.asc` what the entity owes it (`openPayable`); `last.desc` / `.asc` its latest document's business day, a party with none last both ways. Rows that share the key come in the order they were created, in the walk's direction. A cursor resumes only the walk that minted it: change the order and start at the first page."
    },
    "required": false,
    "description": "The walk. `id` (the default): the order parties were written in, the walk it always had. `name.asc` / `.desc` by name, case folded first; `owed.desc` / `.asc` what the party owes (`openReceivable`); `payable.desc` / `.asc` what the entity owes it (`openPayable`); `last.desc` / `.asc` its latest document's business day, a party with none last both ways. Rows that share the key come in the order they were created, in the walk's direction. A cursor resumes only the walk that minted it: change the order and start at the first page.",
    "name": "order",
    "in": "query"
  },
  {
    "schema": {
      "type": "string",
      "minLength": 1,
      "maxLength": 100,
      "description": "A case-insensitive substring of the name, the VAT number in its normal form (`be 0777.000-187` finds `BE0777000187`) or an email (1..100 characters)."
    },
    "required": false,
    "description": "A case-insensitive substring of the name, the VAT number in its normal form (`be 0777.000-187` finds `BE0777000187`) or an email (1..100 characters).",
    "name": "q",
    "in": "query"
  },
  {
    "schema": {
      "type": "string",
      "enum": [
        "buyer",
        "supplier",
        "all"
      ],
      "description": "`buyer`: the parties a new invoice is made out to. Not the entity's own seller party (`sellerPartyId` on the entity, the seller finalize reads), and not one the books know only as a seller (named on an inbound document and on no outbound one); a party on no document yet is listed. `supplier`: the parties named on an inbound document. `all`: every live party but the entity's own. A party that both buys and sells is in both. The trading role is `document.direction`, so it is read from the documents, never stored."
    },
    "required": false,
    "description": "`buyer`: the parties a new invoice is made out to. Not the entity's own seller party (`sellerPartyId` on the entity, the seller finalize reads), and not one the books know only as a seller (named on an inbound document and on no outbound one); a party on no document yet is listed. `supplier`: the parties named on an inbound document. `all`: every live party but the entity's own. A party that both buys and sells is in both. The trading role is `document.direction`, so it is read from the documents, never stored.",
    "name": "role",
    "in": "query"
  }
]
```

### Responses

#### 200 One page of live parties.

```json
{
  "application/json": {
    "schema": {
      "$ref": "#/components/schemas/PartyList"
    }
  }
}
```

#### 401 Dead or absent credential (`unauthenticated`).

```json
{
  "application/problem+json": {
    "schema": {
      "$ref": "#/components/schemas/Problem"
    }
  }
}
```

#### 403 Authenticated, present, and refused: a missing grant, a missing seat, or a missing step-up.

```json
{
  "application/problem+json": {
    "schema": {
      "$ref": "#/components/schemas/Problem"
    }
  }
}
```

#### 404 Absent, or hidden from this asker — the two are indistinguishable (`not-found`).

```json
{
  "application/problem+json": {
    "schema": {
      "$ref": "#/components/schemas/Problem"
    }
  }
}
```

#### 422 The request did not satisfy the schema (`invalid-input`).

```json
{
  "application/problem+json": {
    "schema": {
      "$ref": "#/components/schemas/Problem"
    }
  }
}
```

#### 429 Too many requests on this door's bucket (`rate-limited`); refused before any handler ran, `Retry-After` says when to come back.

```json
{
  "application/problem+json": {
    "schema": {
      "$ref": "#/components/schemas/Problem"
    }
  }
}
```

#### 503 Temporarily unavailable; `Retry-After` says when to come back.

```json
{
  "application/problem+json": {
    "schema": {
      "$ref": "#/components/schemas/Problem"
    }
  }
}
```
