This section contains details about the service APIs in the Machine Master data module
Machines API These APIs include create, update, and fetch APIs. Create and Update API is used by the Administrator Portal for the Create and Update Machine functionality. Fetch APIs are used by Registration Processor to validate the Machine data received in packet to make sure the packet is generated in an authorized Machine.
Machine Types Master API These APIs include Create, Update, Search and Filter API which the Administrator Portal uses. Create and Update API is used for the Create and Update Machine Type functionality. Search API is used by the portal to fetch the list of Machine Types based on a filter criterion to display the list of Machine Types on the UI and Filter API is used by the portal to populate Machine Type Filter Drop downs on the Portal UI.
Machine Specification API These APIs include Create, Update, Search and Filter API which are used by the Administrator Portal. Create and Update API is used for the Create and Update Machine Specification functionality. Search API is used by the portal to fetch the list of Machine Specification based on a filter criterion to display the list of Machine Specification on the UI and Filter API is used to populate Machine Specification Filter Drop downs on the Portal UI.
This service will create the list of Machines which are used in the MOSIP platform. The record needs to be created in primary and secondary language with the same ID so that it becomes active.
POST https://{base_url}/v1/masterdata/machines
Response format
JSON
Requires Authentication
Yes
id
Yes
Id of the machine
ipAddress
No
IP Address of the machine
isActive
Yes
Is the machine active?
langCode
Yes
Language code of the machine
macAddress
No
Mac Address of the machine
machineSpecId
Yes
Machine specification Id of the machine
name
Yes
Name of the machine
publicKey
Yes
Public Key of the machine
serialNum
Yes
Serial number of the machine
validityDateTime
No
Validity date of machine
zoneCode
Yes
Zone code of machine
Response Code: 200 (OK)
Response Code: 200 (OK)
This service will provide the service to fetch the complete List of machines with the machine details.
GET https://{base_url}/v1/masterdata/machines
Response format
JSON
Requires Authentication
Yes
-NA-
Response Code: 200 (OK)
This service will provide the service to fetch the List of machines with the machine details based on the language.
GET https://{base_url}/v1/masterdata/machines/{lang_Code}
Response format
JSON
Requires Authentication
Yes
languagecode
Yes
Machine Languge Code
Response Code: 200 (OK)
This service will provide a service that will verify if a machine (id) was active at a particular time (eff_dtime).
GET https://{base_url}/v1/masterdata/machineshistories/{id}/{lang_code}/{eff_dtimes}
Response format
JSON
Requires Authentication
Yes
ID
Yes
Machine History Id
languagecode
Yes
Language code for the Machine
eff_dtimes
Yes
Effective Date and Time of the Machine
Response Code : 200 (OK)
This service will delete the machines.
DELETE https://dev.mosip.net/v1/masterdata/machines/decommission/{id}
Response format
JSON
Requires Authentication
Yes
machineId
Yes
The machineId
Response Code : 200 (OK)
This service will update existing machines.
PUT /machines
Response format
JSON
Requires Authentication
Yes
id
Yes
Id of the machine
name
Yes
Name of the machine
machineSpecId
Yes
Machine specification Id of the machine
serialNum
Yes
Serial number of the machine
langCode
Yes
Language code of the machine
ipAddress
No
Ip Address of the machine
isActive
Yes
Is the machine active?
validityDateTime
Yes
Validity date of machine
zoneCode
Yes
Zone code of machine
Response Code : 200 (OK)
Response Code : 200 (OK)
KER-MSD-029
Error occured while fetching Machines
Fetch Issue
KER-MSD-063
Error occurred while inserting Machine details
Insertion Issue
KER-MSD-030
Machine not Found
Data Not Found
KER-MSD-087
Error occurred while updating Machine details
Update Issue
KER-MSD-088
Error occurred while deleting Machine details
Deletion Issue
KER-MSD-148
Cannot delete as dependency found
Deletion Issue because of dependency
This service is for the machine search functionality. All the filter parameters are passed and the machines are searched and the matching results are returned.
POST /machines/search
Response format
JSON
Requires Authentication
Yes
filters
No
Array of the filter applied. In case of "list" screen, this array will be empty
-NA-
columnName
No
The column name in the JSON response
-NA-
type
No
The value have to be in ["contains","equals",”startsWith”,"between"]
-NA-
value
No
Value or id selected in the filter by the end user
-NA-
fromValue
No
If the type is "between", this field is the value of the start range
-NA-
toValue
No
If the type is "between", this field is the value of the end range
-NA-
languagecode
Yes
Language code in Language code in ISO 639-2 format
sort
No
This is an array of the sort field and type
sortfield
The field on which the sort is applied
modifiedDate
sorttype
This should be either of ['ASC','DESC']
ASC
pagination
The pagination parameter object
pageStart
This is the start index
0
0
pageFetch
This is the amount of records to be fetched
10
10
Please find the filter columns used in search
name
id
macAddress
serialNum
machineSpecId
ipAddress
langCode
regCenterId
Response Code : 200 (OK)
This service returns the filter values which are required in the dropdown entries of the filter screen.
POST /machines/filtervalues
Response format
JSON
Requires Authentication
Yes
filters
No
Array of the filter applied. In case of "list" screen, this array will be empty
-NA-
columnName
No
The column name in the JSON response
-NA-
type
No
The value have to be in ["unique","all"]
unique
unique
languagecode
Yes
Language code in Language code in ISO 639-2 format
Response Code : 200 (OK)
This service will fetch all the machines mapped to a registration center.
POST https://{base_url}/v1/masterdata/machines/mappedmachines/{reg_center_id}?direction=DESC&orderBy={field_name}&pageNumber=1&pageSize=10
Response format
JSON
Requires Authentication
Yes
direction
No
ASC or DESC
orderBy
No
Column Name
pageNumber
No
Page Number
1
pageSize
No
Page Size
10
-NA-
Success Response
Response Code : 200 (OK)
Failure Response
This service will create the list of Machine types which are used in the MOSIP platform.
POST /machinetypes
Response format
JSON
Requires Authentication
Yes
machinetypecode
Yes
Code of the machine type
machinename
Yes
Name of the machine type
description
Yes
Description of the machine type
languagecode
Yes
Language code of the machine type
isactive
Yes
Is the machine type active?
Response Code : 200 (OK)
Failure details
KER-MSD-061
Error occurred while inserting Machine Type details
Insertion Issue
This service will update the list of Machine types which are used in the MOSIP platform.
PUT /machinetypes
Response format
JSON
Requires Authentication
Yes
machinetypecode
Yes
Code of the machine type
machinename
Yes
Name of the machine type
description
Yes
Description of the machine type
languagecode
Yes
Language code of the machine type
isactive
Yes
Is the machine type active?
Response Code : 200 (OK)
Failure details
KER-MSD-063
Machine Type Not Found
Data Not Found
KER-MSD-064
Error occurred while updating Machine Type details
updation Issue
This service will provides the service to fetch the complete List of machine types with the machine details.
GET /machinetypes
Response format
JSON
Requires Authentication
Yes
-NA-
Response Code : 200 (OK)
This service will provides the service to fetch the List of machines with the machine details based on the language code.
GET /machinetypes/{languagecode}
Response format
JSON
Requires Authentication
Yes
-NA-
Response Code : 200 (OK)
Response Code : 200 (OK)
KER-MSD-061
Error occurred while inserting Machine Type details
Insertion Issue
KER-MSD-062
Error occurred while fetching Machine Type details
Fetch Issue
KER-MSD-063
Machine Type Not Found
Data Not Found
This service is for the machine type search functionality. All the filter parameters are passed and the machines types are searched and the matching results are returned.
POST /machinetypes/search
Response format
JSON
Requires Authentication
Yes
filters
No
Array of the filter applied. In case of "list" screen, this array will be empty
-NA-
columnName
No
The column name in the JSON response
-NA-
type
No
The value have to be in ["contains","equals",”startsWith”,"between"]
-NA-
value
No
Value or id selected in the filter by the end user
-NA-
fromValue
No
If the type is "between", this field is the value of the start range
-NA-
toValue
No
If the type is "between", this field is the value of the end range
-NA-
languagecode
Yes
Language code in Language code in ISO 639-2 format
sort
No
This is an array of the sort field and type
sortfield
The field on which the sort is applied
modifiedDate
sorttype
This should be either of ['ASC','DESC']
ASC
pagination
The pagination parameter object
pageStart
This is the start index
0
10
pageFetch
This is the amount of records to be fetched
10
10
Please find the filter columns used in search
name
status
Response Code : 200 (OK)
This service returns the filter values which are required in the dropdown entries of the filter screen.
POST /machinetypes/filtervalues
Response format
JSON
Requires Authentication
Yes
filters
No
Array of the filter applied. In case of "list" screen, this array will be empty
-NA-
columnName
No
The column name in the JSON response
-NA-
type
No
The value have to be in ["unique","all"]
unique
unique
languagecode
Yes
Language code in Language code in ISO 639-2 format
Response Code : 200 (OK)
This service will create a Machine Specification which are used in the MOSIP platform.
POST /machinespecifications
Response format
JSON
Requires Authentication
Yes
id
Yes
ID of the Machine Specification
name
Yes
Name of the machine Specification
brand
Yes
Brand of the machine specification
model
Yes
Model of the machine specification
mtyp_code
Yes
Machine type code of the machine specification
min_driver_ver
Yes
Minimum driver version required for the machine specification
descr
Yes
Description of the machine specification
lang_code
Yes
Language of the machine specification
is_active
Yes
Is the Machine Specification active
Response Code : 200 (OK)
This service will update a Machine Specification which are used in the MOSIP platform.
PUT /machinespecifications
Response format
JSON
Requires Authentication
Yes
id
Yes
ID of the Machine Specification
lang_code
Yes
Language code of the Machine Specification
Response Code : 200 (OK)
This service deletes a Machine Specification from the Machine Specifications master module.
DELETE /machinespecifications/{id}
Response format
JSON
Requires Authentication
Yes
id
Yes
ID of the Machine Specification
This service will provides the list of all Machine Specifications in all languages.
GET /machinespecifications
Response format
JSON
Requires Authentication
Yes
-NA-
This service will provides the list of all Machine Specifications in a specific language.
GET /machinespecifications/{lang_code}
Response format
JSON
Requires Authentication
Yes
-NA-
Response Code : 200 (OK)
Response Code : 200 (OK)
KER-MSD-062
Error occurred while inserting Machine Specification details
Insertion Issue
KER-MSD-117
Machine Specification not Found
Data Not Found
KER-MSD-085
Error occurred while updating Machine Specification details
Update Issue
KER-MSD-086
Error occurred while deleting Machine Specification details
Deletion Issue
KER-MSD-122
Cannot delete dependency found
Deletion Issue because of dependency
KER-MSD-087
Error occurred while fetching Machine Specification details
Fetch Issue
This service is for the machine specifications search functionality. All the filter parameters are passed and the machines specifications are searched and the matching results are returned.
POST /machinespecifications/search
Response format
JSON
Requires Authentication
Yes
filters
No
Array of the filter applied. In case of "list" screen, this array will be empty
-NA-
columnName
No
The column name in the JSON response
-NA-
type
No
The value have to be in ["contains","equals",”startsWith”,"between"]
-NA-
value
No
Value or id selected in the filter by the end user
-NA-
fromValue
No
If the type is "between", this field is the value of the start range
-NA-
toValue
No
If the type is "between", this field is the value of the end range
-NA-
languagecode
Yes
Language code in Language code in ISO 639-2 format
sort
No
This is an array of the sort field and type
sortfield
The field on which the sort is applied
modifiedDate
sorttype
This should be either of ['ASC','DESC']
ASC
pagination
The pagination parameter object
pageStart
This is the start index
0
10
pageFetch
This is the amount of records to be fetched
10
10
Please find the filter columns used in search
name
isActive
brand
model
machineTypeName
Response Code : 200 (OK)
This service returns the filter values which are required in the dropdown entries of the filter screen.
POST /machinespecifications/filtervalues
Response format
JSON
Requires Authentication
Yes
filters
No
Array of the filter applied. In case of "list" screen, this array will be empty
-NA-
columnName
No
The column name in the JSON response
-NA-
type
No
The value have to be in ["unique","all"]
unique
unique
languagecode
Yes
Language code in Language code in ISO 639-2 format