Townships

Retrieve Township

get

Retrieve a specific Township by ID

Authorizations
Path parameters
idintegerRequired

Unique identifier of the resource

Example: 1
Responses
200
Township retrieved successfully
application/json
get
GET /api/v1/townships/{id}/ HTTP/1.1
Host: sandbox.akinon.com
Authorization: YOUR_API_KEY
Accept: */*
{
  "pk": 1,
  "name": "Esenler",
  "is_active": true,
  "city": 1,
  "translations": {
    "ANY_ADDITIONAL_PROPERTY": "text"
  },
  "postcode": "34000",
  "created_date": "2025-06-27T08:34:37.779Z",
  "modified_date": "2025-06-27T08:34:37.779Z"
}

Update Township

put

Update a specific Township by ID

Authorizations
Path parameters
idintegerRequired

Unique identifier of the resource

Example: 1
Body
pkintegerOptional

Primary key of the township

namestring · stringRequired

Township Name

Example: Esenler
is_activebooleanOptional

Is it active? (True/False)

Example: true
cityinteger · int64Required

Related City ID

postcodestring · stringOptional

Postcode

Example: 34000
Responses
200
Township updated
put
PUT /api/v1/townships/{id}/ HTTP/1.1
Host: sandbox.akinon.com
Authorization: YOUR_API_KEY
Content-Type: application/json
Accept: */*
Content-Length: 113

{
  "pk": 1,
  "name": "Esenler",
  "is_active": true,
  "city": 1,
  "postcode": "34000",
  "modified_date": "2025-06-27T08:34:37.779Z"
}

No content

Delete Township

delete

Delete a specific Township by ID

Authorizations
Path parameters
idintegerRequired

Unique identifier of the resource

Example: 1
Responses
204
Township deleted successfully
delete
DELETE /api/v1/townships/{id}/ HTTP/1.1
Host: sandbox.akinon.com
Authorization: YOUR_API_KEY
Accept: */*

No content

Partial Update Township

patch

Partial update a specific Township by ID

Authorizations
Path parameters
idintegerRequired

Unique identifier of the resource

Example: 1
Body
pkintegerOptional

Primary key of the township

namestring · stringRequired

Township Name

Example: Esenler
is_activebooleanOptional

Is it active? (True/False)

Example: true
cityinteger · int64Required

Related City ID

postcodestring · stringOptional

Postcode

Example: 34000
Responses
200
Township updated
patch
PATCH /api/v1/townships/{id}/ HTTP/1.1
Host: sandbox.akinon.com
Authorization: YOUR_API_KEY
Content-Type: application/json
Accept: */*
Content-Length: 113

{
  "pk": 1,
  "name": "Esenler",
  "is_active": true,
  "city": 1,
  "postcode": "34000",
  "modified_date": "2025-06-27T08:34:37.779Z"
}

No content

Retrieve Township with details

get

Retrieve a specific Township by ID with details

Authorizations
Path parameters
idintegerRequired

Unique identifier of the resource

Example: 1
Responses
200
Township retrieved successfully with details
application/json
get
GET /api/v1/townships/{id}/detailed/ HTTP/1.1
Host: sandbox.akinon.com
Authorization: YOUR_API_KEY
Accept: */*
{
  "city": 1,
  "pk": 1,
  "name": "Esenler",
  "is_active": true,
  "translations": {
    "ANY_ADDITIONAL_PROPERTY": "text"
  },
  "postcode": "34000",
  "created_date": "2025-06-27T08:34:37.779Z",
  "modified_date": "2025-06-27T08:34:37.779Z"
}

List Townships

get

List Townships

Authorizations
Query parameters
pageinteger · min: 1Optional

Specifies the page number of the current dataset

Default: 1
limitinteger · min: 1Optional

Indicates the number of rows on the current page.

Default: 10
name__exactstringOptional

Filters by exact name

name__iexactstringOptional

Filters case insensitive by exact name

mapping__integration_typestring · enumOptional

Filter by integration mapping object's integration type

Possible values:
mapping__code__exactstringOptional

Filter by integration mapping object's code

hyperbooleanOptional

Activate id to hyperlink the response data.

priorityintegerOptional

Filter by priority

Example: 1
city_idinteger · min: 1Optional

Filter by City ID

postcodestringOptional

Filter by Postcode

pk__ininteger[]Optional

Filter by multiple primary key values (comma-separated list of integers)

Responses
200
OK
application/json
get
GET /api/v1/townships/ HTTP/1.1
Host: sandbox.akinon.com
Authorization: YOUR_API_KEY
Accept: */*
{
  "count": 0,
  "next": "text",
  "previous": "text",
  "results": [
    {
      "created_date": "2025-06-27T08:34:37.779Z",
      "modified_date": "2025-06-27T08:34:37.779Z"
    }
  ]
}

Create Township

post

Create Township

Authorizations
Body
pkintegerOptional

Primary key of the township

namestring · stringRequired

Township Name

Example: Esenler
is_activebooleanOptional

Is it active? (True/False)

Example: true
cityinteger · int64Required

Related City ID

postcodestring · stringOptional

Postcode

Example: 34000
Responses
201
Township Created
application/json
post
POST /api/v1/townships/ HTTP/1.1
Host: sandbox.akinon.com
Authorization: YOUR_API_KEY
Content-Type: application/json
Accept: */*
Content-Length: 113

{
  "pk": 1,
  "name": "Esenler",
  "is_active": true,
  "city": 1,
  "postcode": "34000",
  "modified_date": "2025-06-27T08:34:37.779Z"
}
{
  "pk": 1,
  "name": "Esenler",
  "is_active": true,
  "city": 1,
  "translations": {
    "ANY_ADDITIONAL_PROPERTY": "text"
  },
  "postcode": "34000",
  "created_date": "2025-06-27T08:34:37.779Z",
  "modified_date": "2025-06-27T08:34:37.779Z"
}

List Townships with details

get

List Townships with details

Authorizations
Query parameters
pageinteger · min: 1Optional

Specifies the page number of the current dataset

Default: 1
limitinteger · min: 1Optional

Indicates the number of rows on the current page.

Default: 10
name__exactstringOptional

Filters by exact name

name__iexactstringOptional

Filters case insensitive by exact name

mapping__integration_typestring · enumOptional

Filter by integration mapping object's integration type

Possible values:
mapping__code__exactstringOptional

Filter by integration mapping object's code

hyperbooleanOptional

Activate id to hyperlink the response data.

priorityintegerOptional

Filter by priority

Example: 1
city_idinteger · min: 1Optional

Filter by City ID

postcodestringOptional

Filter by Postcode

pk__ininteger[]Optional

Filter by multiple primary key values (comma-separated list of integers)

Responses
200
OK
application/json
get
GET /api/v1/townships/detailed/ HTTP/1.1
Host: sandbox.akinon.com
Authorization: YOUR_API_KEY
Accept: */*
{
  "count": 0,
  "next": "text",
  "previous": "text",
  "results": [
    {
      "pk": 1,
      "name": "Esenler",
      "is_active": true,
      "city": 1,
      "translations": {
        "ANY_ADDITIONAL_PROPERTY": "text"
      },
      "postcode": "34000",
      "created_date": "2025-06-27T08:34:37.779Z",
      "modified_date": "2025-06-27T08:34:37.779Z"
    }
  ]
}

Was this helpful?