---
# System prepended metadata

title: '[208011] Get Directory City Data'

---

[УКР](https://hackmd.io/qckJ3sUqT5C00IvWxsJ4dw) | ENG
![](https://i.imgur.com/ULmPUgP.jpg)
:arrow_left: [Guide](https://hackmd.io/QA2NYRliRLGviJl5P4-ZCw)

# [208011] Get Directory City Data

## Request

*See the description of the "Partner", "KeyAES" and "Sign" attributes in the section "[General API Integration Information](https://hackmd.io/ijxPm0xtTpycgTjuU_NHQQ)".*


### Data Structure

Data structure for this operation is formed from the following parameters:

:::info
<details>
<summary>Data structure formation (examples are below)</summary>
<br>

~~~
{
    "dictionary": "",
    "parentid": "",
    "Transaction": {
        "TransactionID": "",
        "TerminalID": "",
        "DateTime": ""
    }
}
~~~
</details>
:::


|Parameter|Required|Type|Description|Example|
|:----:|:----:|:----:|----|:----:|
| `dictionary` | Yes |String | Value, the data of which must be got from the directory: `city` - names of cities. |`city`|
| `parentid` | Yes |String| Fragment of the city name. |`Dol`|
|`Transaction`|Yes|Structure|Structure transmits the transaction data. See section "[Transaction Structure](https://hackmd.io/ijxPm0xtTpycgTjuU_NHQQ?view#2-Data)".|See example below.| 


:::success
<details>
<summary>Example of the request [208011]</summary>
<br>

~~~md
{
  "Partner": {
    "PartnerToken": "72a8ddb8-9145-4a41-af1a-8c48ecaa4be1",
    "OperationType": 208011,
    "Locale": ""
  },
  "Data": "{\"dictionary\": \"city\", \"parentid\": \"Dol\", \"Transaction\": {\"TransactionID\": \"187725ff2f251\", \"TerminalID\": \"1\", \"DateTime\": \"20230221 120111\"}}",
  "KeyAES": "",
  "Sign": ""
}
~~~
</details>
:::


## Response

*See the general information on the response structure formation in the section "[General API Integration Information](https://hackmd.io/ijxPm0xtTpycgTjuU_NHQQ)"*.

### Data Structure

Data structure of the response is formed from the following parameters:

|Parameter|Required|Type|Description|Example|
|:----:|:----:|:----:|----|:----:|
| `result`^1^ | Yes | Array | Array of structures transmits the data on the requested city. | See example below.|


^1^ Parameters of the **"result"** array:

|Parameter|Required|Type|Description|Example|
|:----:|:----:|:----:|----|:----:|
| `kommuna_area` | Yes | String | City area (district). |`Obuhivsky`|
| `kommuna_sity` | Yes | String | City full name.|`Dolina`|
| `kommuna_state` | Yes | Integer | City state (region). |`Kyiv region`|
| `sity_id` | Yes | String | City unique identifier from the directory. |`27314002`|


### Response Examples

:::success
<details>
<summary>Operation Successfully Completed</summary>
<br>

~~~md
{
   "Code": 200,
   "Message": "Address find",
   "Data": {
     "OperationDate": "2023-02-21T15:54:42.129914+02:00",
     "OperationID": 9488897,
     "OperationStatus": 10,
     "result": [
       {
         "kommuna_area": "Obuhivskyi",
         "kommuna_sity": "Dolina",
         "kommuna_state": "Kyiv Region",
         "city_id": "27314002"
       }
     ]
   },
   "KeyAES": "",
   "Sign": ""
}
~~~
</details>
:::

:::success
<details>
<summary>Operation Failed</summary>
<br>

~~~md
{
   "Code": 200,
   "Message": "done",
   "Data": {
     "OperationID": 111,
     "OperationStatus": 21,
     "Reason": 3
   },
   "KeyAES": "",
   "Sign": ""
}
~~~
</details>
:::


## Related Requests

[[20801] Get Directory Data](https://hackmd.io/8x6rVjR-SnOj1HHwAfa8tg)
[[20802] Get Debt Data](https://hackmd.io/GuQz5QT-RpGfdoqKjhMd8g)
[[10108] Debt Repayment](https://hackmd.io/9MdA15b8Ra-SS1pGfia0oQ)


## Reference Materials

General parameters of the XPAY system are given in the section ["Reference Materials"](https://hackmd.io/16yLv895Qo-FWTvrWWQwbg):  operation types, payment types, response codes, operation status, reasons of operation rejection, etc.


![](https://i.imgur.com/17gAyWb.png)
:arrow_left: [Guide](https://hackmd.io/QA2NYRliRLGviJl5P4-ZCw)
:arrow_left: [General API Integration Information](https://hackmd.io/ijxPm0xtTpycgTjuU_NHQQ)

<details>
<summary>XPAY Support</summary>
</br>

Phone: +38 093 891 92 00
Email: info@xpay.com.ua
Telegram: @xpaysupportbot
</details>
























