# Add a Card Number

> Solarium docs, Accounts. All requests are `POST https://api.trysolarium.com/graphql/` with `Authorization: Bearer <api key>` and a JSON body `{"query": ..., "variables": ...}`. Every query and mutation takes an `organizationId` (find it with `myOrganizations`). Index of all pages: https://trysolarium.com/llms.txt

Remembers another last-4 for a card (e.g. its Apple Pay number or a reissued card), so receipts showing any of the card's numbers land on it. Any waiting receipts that show this number are filed to the card. A number can belong to only one account.

### Arguments

| Name | Type | Required | Description |
| --- | --- | --- | --- |
| `accountId` | `UUID!` | Yes | The card or bank account |
| `lastFour` | `String!` | Yes | Exactly 4 digits |

### Request

```graphql
mutation {
  addCardNumber(accountId: "c3d4e5f6-...", lastFour: "6659") {
    success
    error
    receiptsResolved
    account {
      name
      cardNumbers { lastFour source }
    }
  }
}
```

### Response

```json
{
  "data": {
    "addCardNumber": {
      "success": true,
      "error": null,
      "receiptsResolved": 1,
      "account": {
        "name": "Personal CC",
        "cardNumbers": [
          { "lastFour": "6859", "source": "account" },
          { "lastFour": "6659", "source": "manual" }
        ]
      }
    }
  }
}
```
