Hide If | |||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| |||||||||||||||||||||||
|
Show If | ||||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| ||||||||||||||||||||||||
For every single of operation on the entities use the following templates and provide sample REST requests and responses.
Filtering and attribute selection rules are described in the TMF REST Design Guidelines. GET /usageManagement/usage |
For every single of operation on the entities use the following templates and provide sample REST requests and responses.
Remember that the following Uniform Contract rules must be used :
Operation on Entities | Uniform API Operation | Description |
Query Entities | GET Resource | GET must be used to retrieve a representation of a resource. |
Create Entity | POST Resource | POST must be used to create a new resource |
Partial Update of an Entity | PATCH Resource | PATCH must be used to partially update a resource |
Complete Update of an Entity | PUT Resource | PUT must be used to completely update a resource identified by its resource URI |
Remove an Entity | DELETE Resource | DELETE must be used to remove a resource |
Execute an Action on an Entity | POST on TASK Resource | POST must be used to execute Task Resources |
Other Request Methods | POST on TASK Resource | GET and POST must not be used to tunnel other request methods. |
Filtering and attribute selection rules are described in the TMF REST Design Guidelines.
Notifications are also described in a subsequent section.
...
Example REQUEST |
GET /usageManagement/usage/1234/fields=date,usageType,usageDescription |
Example RESPONSE |
200 Content-Type: application/json { "date": "2013-05-31T09:00:00+00:01", |
Example REQUEST B |
GET /usageManagementi/usage/?fields=date,usageType,status,ratedProductUsage.taxIncludedRatingAmount& ratedProductUsage.taxIncludedRatingAmount.gt=10 |
Example RESPONSE B |
200 Content-Type: application/json
{ "date": " 2013-04-19T16:42:23-04:00", |
...
/{ID}
|
entities. |
...
usage/{ID} |
...
/{attributeSelector} |
...
?{ |
...
filtering expression}
|
...
|
...
|
...
...
|
...
|
...
|
...
|
...
|
...
|
...
GET /usageManagement/usageSpecification/{ID}The resource is used to retrieve the usage specification entities.
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
|
...
Example REQUEST B
...
GET usageManagement/usageSpecification/?name="cloudCpuSpec"
Accept: application/json
...
Example RESPONSE B
|
...
POST /usagemanagement/usageThe resource is used to create usage entities.
Create a usage
|
...
...
POST usageManagement/usageSpecification/The resource is used to create usage specification entities.
|
...
...
PATCH usagemanagement/USAGEThe resource is used to modify usage entities.
|
...
...
DELETE usagemanagement/USAGESPECificationThe resource is used to DELETE a usage specification entity.
|
...
...
POST usageManagement/importJobImportJob Tasks are created as resources.
|
...
...
...
POST usageManagement/exportJobExportJob Tasks are created as resources.
|
...
...
...
GET usageManagement/exportJob
|
...
...
...
GET usageManagement/IMPORTJob
|