---
title: Sync Device Credentials
slug: jetstream-v3/sync-device-credentials
docTags: 
createdAt: 2024-01-23T15:32:59.033Z
---

## About

Instruct the specified device to set/sync its access control list to the credentials associated with the specified device in Jetstream.

| **Command Type**       | **Device is Online**                                         | **Device is Offline**               |
| ---------------------- | ------------------------------------------------------------ | ----------------------------------- |
| Synchronous, Queueable | Immediate execution, Immediate results and published results | Queued execution, Published results |

## Parameters

| **Property**                                                         | **Location** | **Details**                                                                                                                                                      |
| -------------------------------------------------------------------- | ------------ | ---------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| **AccessKey**<br />:::BlockQuote
string&#xA;Required&#xA;Unique
:::  | Header       | The access key for your user account.<br />This value is a 36-character GUID provided in your [user profile](docId\:BbIFQiuIXND5iAfMreBBi).                      |
| **DeviceName**<br />:::BlockQuote
string&#xA;Required&#xA;Unique
::: | URL          | The name of the device.<br />This value has a max length of 128 ASCII characters.<br />This value must adhere to this regular expression: ^\[a-zA-Z0-9-\_,. ]\*$ |

## Example

### Request URL

**POST** https\://api.jetstreamrfid.com/3/devices/\{Device Name}/credentials/sync

### Request Body

None Required

### Response Code

200 OK

### Response Body

:::BlockQuote
\{
&#x20;   "CommandId": "5be4a19c-f1c3-42a9-b437-eacf5272bb8d",
&#x20;   "Status": "Completed",
&#x20;   "ExceptionList": \[],
&#x20;   "OutputParameterList": \[]
}
:::

### Published CommandQueuedEvent

:::BlockQuote
\{
&#x20;   "Device": "MyDeviceName",
&#x20;   "CommandId": "5be4a19c-f1c3-42a9-b437-eacf5272bb8d",
&#x20;   "CommandName": "SyncCredentials",
&#x20;   "URI": "/3/Devices/MyDeviceName/credentials/sync",
&#x20;   "Verb": "Post",
&#x20;   "User": "MyUserName",
&#x20;   "Parameters": \[
&#x20;       \{
&#x20;           "Key": "Add"
&#x20;           "Value": "MyBasicCredentials1\_Value"
&#x20;       },
&#x20;       \{
&#x20;           "Key": "Add",
&#x20;           "Value": "MyBasicCredentials2\_Value"
&#x20;       },
&#x20;       \{
&#x20;           "Key": "Add",
&#x20;           "Value": "MyBasicCredentials3\_Value"
&#x20;       },
&#x20;       \{
&#x20;           "Key": "Remove",
&#x20;           "Value": "\*"
&#x20;       }
&#x20;   ],
&#x20;   "Type": "CommandQueuedEvent",
&#x20;   "EventId": "7e830645-0c77-4a1d-9666-1e5b6c320947",
&#x20;   "EventTime": "2018-05-17T13:51:08Z",
&#x20;   "Version": 2
}
:::

### Published CommandCompletionEvent

:::BlockQuote
\{
&#x20;   "CommandId": "0093fac7-1d82-430a-8bd2-0562c2067037",
&#x20;   "CommandName": "SyncCredentials",
&#x20;   "OutputParameterList": \[],
&#x20;   "ExceptionList": \[],
&#x20;   "Device": "MyDeviceName",
&#x20;   "ReceivedTime": "2018-05-16T21:17:13Z",
&#x20;   "Type": "CommandCompletionEvent",
&#x20;   "EventId": "59236a58-2581-4f10-be5c-44c11e681794",
&#x20;   "EventTime": "2018-05-16T21:17:12Z",
&#x20;   "Version": 2
}
:::

## Version Changes

A combination of this endpoint, [Create Device Credentials](docId:-Y-XFsvUX_FyloqYUZQMR), [Modify Device Credentials](docId\:J3NcV3RiuIbv506_jobzd), and [Delete Device Credentials](docId:6Bj1ETRYZO_PaajN3Zasg) replaces Add and/or Remove Passes and Replace All Passes.
