Initialize Device

POST/api/v1/initialize

Initialize your OSCU device with Kenya Revenue Authority and perform an initial sync of all reference data in a single call. This is the recommended way to onboard a new device.

Requires x-api-key

http://localhost:8100/api/v1/initialize

When to Use This vs /setup

POST /initialize

Headers

FieldTypeRequiredDescription
x-api-keystringRequiredYour Ushuru API key
Content-TypestringRequiredMust be application/json

Request Body

FieldTypeRequiredDescription
deviceSerialNumberstringOptionalPhysical device serial number. Uses the default device if omitted.

Request

{}

Response

{
  "resultCd": "000",
  "resultMsg": "Success",
  "data": {
    "deviceInfo": {
      "sdcId": "SDC12345678",
      "mrcNo": "MRC0001",
      "deviceStatus": "ACTIVE"
    },
    "syncResult": {
      "codes": true,
      "notices": true,
      "branches": true
    }
  }
}
curl -X POST http://localhost:8100/api/v1/initialize \\
  -H "x-api-key: YOUR_API_KEY" \\
  -H "Content-Type: application/json" \\
  -d '{}'