Specifying Identifiers in REST API Calls
If an identifier has already been generated by an application, it can specify the identifier when creating new objects and datastreams using the PUT method in the REST API:
PUT /rest/abc123
Response:
Status: 201 Created Headers: Location: http://localhost:8080/rest/abc123
Internal PID Minter
To have identifiers automatically generated using the internal PID minter, an application can use the POST method in the REST API:
POST /rest
Response:
Status: 201 Created Headers: Location: http://localhost:8080/rest/5b6ff353-b4fc-4b9a-8e36-89f74645327b
External PID Minter
Fedora 4 can also be configured to retrieve identifiers from an external HTTP minter service. When a new object or datastream is created using the POST method, a new identifier will be created using the external PID minter. See Configuring an External PID Minter.
Custom PID Minters
To use a different identifier generation process, you can create a custom PID minter implementation, which can be configured in the same way as the external PID minter. If your identifiers are generated from an HTTP service, then you should consider improving or extending HttpPidMinter.java to provide the needed functionality. Otherwise, you can create a new implementation of the PidMinter interface.