Skip to content
On this page

Search KCCA Trading Licence verification Requests

Endpoint for searching for KCCA Licence Verification request by selected criteria.

EnvironmentURL
Sandbox``
Productionhttps://api.streamline.laboremus.ug/kcca/api/verifylicense?v=1.0

Request

Request Type : GET

Authorization

There are two ways to be authorized when making this request.

js
const token = 'eyJhbGciOiJIUzI1NiIsInR5.eyJzd...ssw5c'
axios.get(API_ENDPOINT, 
  headers: {
    Authorization: `Bearer ${token}`
  }
)
const token = 'eyJhbGciOiJIUzI1NiIsInR5.eyJzd...ssw5c'
axios.get(API_ENDPOINT, 
  headers: {
    Authorization: `Bearer ${token}`
  }
)
js
import axios from 'axios'
    import oauth from 'axios-oauth-client'
    
    const getClientCredentials = oauth.clientCredentials(
    axios.create(),
    'https://oauth.com/2.0/token',
    'CLIENT_ID',
    'CLIENT_SECRET'
    )

    const auth = await getClientCredentials('OPTIONAL_SCOPES')
    // => { "access_token": "...", "expires_in": 900, ... }

    axios.get(API_ENDPOINT, 
      headers: {
        Authorization: `Bearer ${auth.access_token}`
      }
    )
import axios from 'axios'
    import oauth from 'axios-oauth-client'
    
    const getClientCredentials = oauth.clientCredentials(
    axios.create(),
    'https://oauth.com/2.0/token',
    'CLIENT_ID',
    'CLIENT_SECRET'
    )

    const auth = await getClientCredentials('OPTIONAL_SCOPES')
    // => { "access_token": "...", "expires_in": 900, ... }

    axios.get(API_ENDPOINT, 
      headers: {
        Authorization: `Bearer ${auth.access_token}`
      }
    )

INFO

Always add your Subscription key to the request.

js
axios.get(API_ENDPOINT, 
  headers: {
    'Ocp-Apim-Subscription-Key': 'd484a1f0d34f43019'
  }
)
axios.get(API_ENDPOINT, 
  headers: {
    'Ocp-Apim-Subscription-Key': 'd484a1f0d34f43019'
  }
)
js
const res = await axios.get(API_ENDPOINT, { 
  params: { 
    Ocp-Apim-Subscription-Key: 'd484a1f0d34f43019' 
  } 
});
const res = await axios.get(API_ENDPOINT, { 
  params: { 
    Ocp-Apim-Subscription-Key: 'd484a1f0d34f43019' 
  } 
});

Header Parameters

NameTypeRequiredDescription
Bearerstring(JwtToken)noThe token for accessing the resource

Query Parameters Values

NameTypeRequiredDescription
vstringyesThe version of the API
IdstringnoSearch for a request using the unique ID.
ApplicationReferencestringnoSearch for a request using the application reference.
Date.Fromstring(date-time)noThe start date of the date range.
Date.Tostring(date-time)noThe end date of the date range.
CoinstringnoSearch using City Operator Identification Number (COIN).
Statusstring (Enum : Pending, Successful, Failed)noSearch using the status of the request.
BusinessNamestringnoSearch using the business Name.
TaxPayerNamestringnoSearch using the tax payer Name.
TinstringnoSearch using the Tax Identification Number.
DivisionstringnoSearch using the division in which the business is situated.
ParishstringnoSearch using the parish in which the business is situated.
CategorystringnoSearch using the category in which the business is.
NaturestringnoSearch using the category in which the business is.
PRNstringnoSearch using the category in which the business is.
InitiatorstringnoSearch using the user that initiated the request.
Amountnumber (double)noSearch using the Amount paid by a business.
Yearinteger (int32)noSearch using the Year of the licences for a business.
Pagination.Pageinteger (int32)noPage number
Pagination.ItemsPerPageinteger (int32)noNumber of requests returned per page.
Pagination.TotalItemsinteger (int32)noTotal number of requests.

Response

Content type

application/json

Response Values

NameTypeDescription
paginationobject (uuid)The details of pagination of the requests.
requestsArray of objects or nullA list of the requests that match a search criteria.

pagination

NameTypeDescription
pageintegerPage number
itemsPerPageobjectNumber of requests returned per page
totalItemsstring or nullTotal number of requests

requests

NameTypeDescription
idstring (uuid)The unique Id of the request.
applicationReferencestring or nullThe application reference of a given verification request.
statusstring (Pending,Successful,Failed)The code of the error returned.
textstring or nullThe verification description.
successbooleanTrue if the request was processed, and false if it was not processed.
isErrorbooleanTrue if there was an error that occurred during the verification process.
errorCodeinteger or null (int32)The error code, if isError is true.
coininteger or null (int32)The City Operator Identification Number.
taxPayerNamestring or nullThe name of the tax-payer.
tinstring or nullThe Tax Identification Number of the tax-payer.
businessNamestring or nullThe name of the business.
categorystring or nullThe category in which the business is.
naturestring or nullThe nature of the business.
yearinteger or null (int32)The year in which the business was licenced.
issueDatestring or null (date-time)The date in which the licence was issued.
expiryDatestring or nullThe expiry date of the licence.
amountnumber or null (double)The amount paid by the business.
divisionstring or nullThe division in which the business is situated.
parishstring or nullThe parish in which the business is situated.
villagestring or nullThe village in which the business is situated.
streetstring or nullThe street on which the business is situated.
buildingstring or nullThe building in which the business is situated.
shopNostring or nullThe shop number which the business is situated.
prnstring or nullThe Payment Reference Number used to track payments.
initiatorstring or nullThe user that initiated the request.
sentAtstring or null (date-time)Date the request was sent.
processedAtstring or null (date-time)Date at which the verification request was processed.
createdAtstring or null (date-time)Date at which the verification request was created.
lastUpdatedstring or null (date-time)Date at which the verification request was last updated.

Example Response Body

json
{
	"pagination": {
		"page": 0,
		"itemsPerPage": 0,
		"totalItems": 0
	},
	"requests": [
		{
			"id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
			"applicationReference": "string",
			"status": "Pending",
			"text": "string",
			"success": true,
			"isError": true,
			"errorCode": 0,
			"coin": 0,
			"taxPayerName": "string",
			"tin": "string",
			"businessName": "string",
			"category": "string",
			"nature": "string",
			"year": 0,
			"issueDate": "2019-08-24T14:15:22Z",
			"expiryDate": "string",
			"amount": 0,
			"division": "string",
			"parish": "string",
			"village": "string",
			"street": "string",
			"building": "string",
			"shopNo": "string",
			"prn": "string",
			"initiator": "string",
			"sentAt": "2019-08-24T14:15:22Z",
			"processedAt": "2019-08-24T14:15:22Z",
			"createdAt": "2019-08-24T14:15:22Z",
			"lastUpdated": "2019-08-24T14:15:22Z"
		}
	]
}
{
	"pagination": {
		"page": 0,
		"itemsPerPage": 0,
		"totalItems": 0
	},
	"requests": [
		{
			"id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
			"applicationReference": "string",
			"status": "Pending",
			"text": "string",
			"success": true,
			"isError": true,
			"errorCode": 0,
			"coin": 0,
			"taxPayerName": "string",
			"tin": "string",
			"businessName": "string",
			"category": "string",
			"nature": "string",
			"year": 0,
			"issueDate": "2019-08-24T14:15:22Z",
			"expiryDate": "string",
			"amount": 0,
			"division": "string",
			"parish": "string",
			"village": "string",
			"street": "string",
			"building": "string",
			"shopNo": "string",
			"prn": "string",
			"initiator": "string",
			"sentAt": "2019-08-24T14:15:22Z",
			"processedAt": "2019-08-24T14:15:22Z",
			"createdAt": "2019-08-24T14:15:22Z",
			"lastUpdated": "2019-08-24T14:15:22Z"
		}
	]
}

Error Response

400 Bad Request

application/json

NameTypeDescription
errorobject(Error)Type of error response

Error

NameTypeDescription
codestring or nullThe Error code
messagestring or nullThe Error message

401 Unauthorized

application/json

NameTypeDescription
errorobject(Error)Type of error response

Error

NameTypeDescription
codestring or nullThe Error code
messagestring or nullThe Error message

403 Forbidden

application/json

NameTypeDescription
errorobject(Error)Type of error response

Error

NameTypeDescription
codestring or nullThe Error code
messagestring or nullThe Error message

404 Not Found

application/json

NameTypeDescription
errorobject(Error)Type of error response

Error

NameTypeDescription
codestring or nullThe Error code
messagestring or nullThe Error message

500 Server Error

application/json

NameTypeDescription
errorobject(Error)Type of error response

Error

NameTypeDescription
codestring or nullThe Error code
messagestring or nullThe Error message

Tech served right