# sinch porting

Manage number porting — check portability, create port-in orders, upload supporting documents, and activate ported numbers. Number porting is the process of bringing phone numbers you already own with another carrier over to Sinch so you can use them with Sinch Voice, SMS, and other products without losing the number.

Use these commands when you want to migrate existing phone numbers from a current provider to Sinch. A typical port-in flow looks like: run a portability check, update your porting contact info, create a port-in order for the numbers, upload any supporting documents the losing carrier requires, then activate the numbers once the port completes.

```
sinch porting
├── check          — portability checks for one or more numbers
├── config         — porting contact info, webhook URL, default port times
├── orders         — port-in order lifecycle (create, list, get, update, cancel, notes)
├── documents      — upload and download supporting documents
└── activation     — list activation groups and activate on-demand orders
```

All commands accept `--json` for machine-readable output.

## sinch porting check

Check whether one or more phone numbers are portable to Sinch.

```sh
sinch porting check <numbers...> [--json]
```

| Option | Description |
|  --- | --- |
| `<numbers>` | One or more E.164 phone numbers to check |
| `--json` | Output raw JSON |


**Example**

```sh
sinch porting check +15551234567 +15557654321
```

## sinch porting config

Manage the porting configuration for your project — contact information, webhook URL for port status updates, and default port times.

### sinch porting config get

Get the current porting configuration.

```sh
sinch porting config get [--json]
```

| Option | Description |
|  --- | --- |
| `--json` | Output raw JSON |


### sinch porting config update

Update the porting configuration. Runs interactively by default, pre-filled with the current values. Pass `--non-interactive` with the flags you want to change to skip prompts.

```sh
sinch porting config update [options]
```

| Option | Description |
|  --- | --- |
| `--contact-name <name>` | Contact name |
| `--contact-email <email>` | Contact email |
| `--contact-phone <phone>` | Contact phone |
| `--webhook-url <url>` | Webhook URL for port status notifications |
| `--default-port-time <time>` | Default port time in `HH:MM` format |
| `--default-timezone <tz>` | Default timezone: `US/Eastern`, `US/Central`, `US/Mountain`, `US/Pacific` |
| `--non-interactive` | Skip prompts, use provided flags only |
| `--json` | Output raw JSON |


**Example**

```sh
sinch porting config update \
  --contact-name "Jane Doe" \
  --contact-email jane@example.com \
  --webhook-url https://example.com/porting-webhook \
  --non-interactive
```

## sinch porting orders

Create and manage port-in orders — the request to move numbers from another carrier to Sinch.

### sinch porting orders create

Create a new port-in order. Runs interactively by default. For scripting, use `--non-interactive` with flags, or supply the full request body as a JSON file via `--from-file`.

```sh
sinch porting orders create [options]
```

| Option | Description |
|  --- | --- |
| `--number <e164>` | Phone number to port — repeat for multiple numbers |
| `--from-file <path>` | Full request body as JSON file |
| `--port-date <YYYY-MM-DD>` | Desired port date |
| `--port-time <HH:MM>` | Desired port time |
| `--port-timezone <tz>` | Timezone (e.g. `US/Eastern`) |
| `--end-user-name <name>` | End user name |
| `--end-user-street-num <num>` | End user street number |
| `--end-user-street-name <name>` | End user street name |
| `--end-user-city <city>` | End user city |
| `--end-user-state <state>` | End user state |
| `--end-user-zip <zip>` | End user ZIP code |
| `--service-type <B|R>` | Service type: `B` (Business) or `R` (Residential) |
| `--port-out-pin <pin>` | Port-out PIN from the losing carrier |
| `--account-num <num>` | Account number with the losing carrier |
| `--customer-ref <ref>` | Customer-side order reference |
| `--on-demand-activation` | Enable on-demand activation (activate manually after port) |
| `--non-interactive` | Skip prompts, fail if required options not provided |
| `--json` | Output raw JSON |


**Example**

```sh
sinch porting orders create \
  --number +15551234567 \
  --number +15557654321 \
  --port-date 2026-05-01 \
  --port-time 10:00 \
  --port-timezone US/Eastern \
  --service-type B \
  --account-num 987654321 \
  --non-interactive
```

### sinch porting orders list

List port-in orders with optional filters.

```sh
sinch porting orders list [options]
```

| Option | Description |
|  --- | --- |
| `--status <status>` | `PENDING`, `CONFIRMED`, `COMPLETED`, `PENDING_CANCELATION`, or `CANCELED` |
| `--limit <n>` | Page size (default `100`, max `1000`) |
| `--page-token <token>` | Pagination token from a previous response |
| `--phone-number <e164>` | Filter by phone number |
| `--created-after <date>` | Filter by creation date start (ISO-8601) |
| `--created-before <date>` | Filter by creation date end (ISO-8601) |
| `--customer-ref <ref>` | Filter by customer order reference |
| `--json` | Output raw JSON |


### sinch porting orders get

Get the full details of a port-in order.

```sh
sinch porting orders get <orderId> [--json]
```

### sinch porting orders update

Update a pending port-in order. Interactive by default and fetches the current order so unchanged fields are preserved. Use `--from-file` to replace the entire request body.

```sh
sinch porting orders update <orderId> [options]
```

| Option | Description |
|  --- | --- |
| `<orderId>` | Port-in order ID |
| `--from-file <path>` | Full request body as JSON file (replaces body) |
| `--port-date <YYYY-MM-DD>` | Updated port date |
| `--port-time <HH:MM>` | Updated port time |
| `--customer-ref <ref>` | Updated customer order reference |
| `--non-interactive` | Skip prompts, use provided flags only |
| `--json` | Output raw JSON |


### sinch porting orders cancel

Cancel a pending port-in order. Prompts for confirmation by default.

```sh
sinch porting orders cancel <orderId> [--force] [--json]
```

| Option | Description |
|  --- | --- |
| `--force` | Skip confirmation prompt |
| `--json` | Output raw JSON |


### sinch porting orders add-note

Add a note to a port-in order. Useful for recording context or responding to carrier requests.

```sh
sinch porting orders add-note <orderId> [--note <text>] [options]
```

| Option | Description |
|  --- | --- |
| `--note <text>` | Note text — prompted for if omitted |
| `--non-interactive` | Skip prompts, fail if `--note` not provided |
| `--json` | Output raw JSON |


## sinch porting documents

Upload and retrieve supporting documents attached to a port-in order. Losing carriers often require a Letter of Authorization (LOA) or a copy of a recent bill.

### sinch porting documents upload

Upload a document to a port-in order. The file is base64-encoded and sent inline.

```sh
sinch porting documents upload <orderId> --file <path> [options]
```

| Option | Description |
|  --- | --- |
| `<orderId>` | Port-in order ID |
| `--file <path>` | Path to the file to upload (**required**) |
| `--name <name>` | Document name (defaults to filename) |
| `--description <text>` | Document description |
| `--non-interactive` | Skip prompts, fail if required options not set |
| `--json` | Output raw JSON |


**Example**

```sh
sinch porting documents upload ord_123 \
  --file ./loa.pdf \
  --description "Letter of Authorization"
```

### sinch porting documents get

Download a document from a port-in order. Saves the decoded file to disk by default; use `--json` to print metadata only without writing a file.

```sh
sinch porting documents get <orderId> <documentId> [options]
```

| Option | Description |
|  --- | --- |
| `<orderId>` | Port-in order ID |
| `<documentId>` | Document ID |
| `--output <path>` | Output file path (defaults to `./<documentName>` in current dir) |
| `--json` | Output metadata only, no file download |


## sinch porting activation

Manage activation of ported numbers. When a port-in order uses on-demand activation, numbers are ported but not yet live — they must be explicitly activated, optionally in groups.

### sinch porting activation list

List the available activation groups for a port-in order.

```sh
sinch porting activation list <orderId> [--json]
```

### sinch porting activation activate

Activate ported numbers for an order. Without `--group`, activates all available groups. Prompts for confirmation by default.

```sh
sinch porting activation activate <orderId> [options]
```

| Option | Description |
|  --- | --- |
| `<orderId>` | Port-in order ID |
| `--group <name>` | Specific group to activate — repeat for multiple groups |
| `--force` | Skip confirmation prompt |
| `--json` | Output raw JSON |


**Example**

```sh
sinch porting activation activate ord_123 --group group-1 --group group-2
```

## Authentication

Porting commands use the standard OAuth2 project credentials (Project ID, Key ID, Key Secret) stored by `sinch auth login`. If you have not authenticated yet, run `sinch auth login` before using any porting command.