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.
GET /partyManagement/individual/{ID}
Note that collections can be retrieved via GET /api/INDIVIDUAL with no {ID}
Description :
- Operation to retrieve individuals (physical persons) in a party repository
- Filtering is enabled for all attributes
- Attribute selection is enabled for all attributes
- The resource is either a managed entity (query by id) or a collection (query with criteria)
- The resource identifier is a http uri
Behavior :
- Standard behavior and response codes for GET operations
Example : Retrieve individual with id 11 who is John Doe - with all his attributes.
REQUEST |
GET /partyManagement/individual/i42 Accept: application/json |
RESPONSE |
200 Content-Type: application/json { "id": "i42", "href": "http://serverlocation:port/partyManagement/individual/i42", "gender": "male", "placeOfBirth": "http://goo.gl/maps/l8F9L", "countryOfBirth": "Austria", "nationality": "Canadian", "maritalStatus": "never married", "disability": [ { "disability": "blind" } ], "birthDate": "1961-03-05T00:00:00.0Z", "characteristic": [ { "name": "hobby", "value": "hockey" }, { "name": "", "value": "" } ], "title": "", "givenName": "John", "familyName": "Smith", "middleName": "", "fullName": "", "formattedName": "", "otherName": [ { "title": "", "givenName": "", "familyName": "", "middleName": "", "fullName": "", "formattedName": "", "validFor": { "startDateTime": "2013-04-19T16:42:23.0Z", "endDateTime": "2013-06-19T00:00:00.0Z" } } ], "location": "http://goo.gl/maps/l8F9L", "status": "Initialized", "individualIdentification": [ { "type": "Passport", "identificationId": "73736625252", "issuingAuthority": "", "issuingDate": "2013-06-19T00:00:00.0Z" }, { "type": "SocialSecurityNumber", "identificationId": "33636363", "issuingAuthority": "", "issuingDate": "2013-06-19T00:00:00.0Z" } ], "externalReference": [ { "href": "http://facebook.com/17263635", "type": "FacebookID" }, { "href": "http://google.com/17263635", "type": "GoogleID" } ], "relatedParty": [ { "id": "1", "href": "http://serverlocation:port/partyManagement/organization/1", "role": "Employee", "name": "Richard Cole", "validFor": { "startDateTime": "2013-04-19T16:42:23.0Z", "endDateTime": "2013-06-19T00:00:00.0Z" } } ], "contactMedium": [ { "type": "Email", "validFor": { "startDateTime": "2013-04-19T16:42:23.0Z" }, "medium": { "emailAddress": "[email protected]" } }, { "type": "PostalAddress", "validFor": { "startDateTime": "2013-04-19T16:42:23.0Z" }, "medium": { "city": "Wien", "country": "Austria", "postcode": "1020", "stateOrProvince": "Quebec", "street1": "Lassallestrasse7", "street2": "" } }, { "type": "TelephoneNumber", "validFor": { "startDateTime": "2013-04-19T16:42:23.0Z" }, "medium": { "type": "mobile", "number": "+436641234567" } }, { "preferred": true, "type": "TelephoneNumber", "validFor": { "startDateTime": "2013-04-19T16:42:23.0Z" }, "medium": { "type": "business", "number": "+436641234567" } } ] } |
Example : Retrieve John Doe individual entry and we only want to get his full name.
REQUEST |
GET /partyManagement/individual/11?fields=fullName Accept: application/json |
RESPONSE |
200 Content-Type: application/json { "fullName": "Dr. John Doe" } |
GET /partyManagement/organization/{ID}
Note that collections can be retrieved via GET /api/<RESOURCE> with no {ID}
Description :
- Operation to retrieve organizations (corporations) in a party repository
- Filtering is enabled for all attributes
- Attribute selection is enabled for all attributes
- The resource is either a managed entity (query by id) or a collection (query with criteria)
- The resource identifier is a http uri
Behavior :
- Standard behavior and response codes for GET operations
Example : Get all names of children organizations of a given one (131)
REQUEST |
GET /partyManagement/organization?fields=tradingName&organizationParentRelationship.id=131 Accept: application/json |
RESPONSE |
200 Content-Type: application/json [ { "id": "1311", "tradingName": "IT" }, { "id": "1312", "tradingName": "Network" } ] |
Example : Get specific organization using its id returning all attributes
REQUEST |
GET /partyManagement/organization/128 Accept: application/json |
RESPONSE |
200 Content-Type: application/json { "id": "128", "href": "http://serverlocation:port/partyManagement/organization/128", "isLegalEntity": true, "type": "Company", "existsDuring": { "startDate": "2013-04-19T16:42:23.0Z" }, "tradingName": "Telekom", "nameType": "Co.", "status": "Initialized", "otherName": { "nameType": "Co.", "tradingName": "Orange", "validFor": { "startDateTime": "2013-04-19T16:42:23.0Z", "endDateTime": "2013-06-19T00:00:00.0Z" } }, "characteristic": { "name": "industry", "value": "telecom" }, "organizationIdentification": { "type": "CompanyRegistrationNumber", "identificationId": "374748328", "issuingAuthority": "", "issuingDate": "2013-06-19T00:00:00.0Z", "validFor": { "startDateTime": "2013-04-19T16:42:23.0Z", "endDateTime": "2013-06-19T00:00:00.0Z" } }, "externalReference": [ { "href": "http://facebook.com/17263635", "type": "FacebookID" }, { "href": "http://google.com/17263635", "type": "GoogleID" } ], "relatedParty": { "id": "12", "href": "http://serverlocation:port/partyManagement/organization/12", "role": "Vendor", "name": "Richard Cole", "validFor": { "startDateTime": "2013-04-19T16:42:23.0Z", "endDateTime": "2013-06-19T00:00:00.0Z" } }, "organizationParentRelationship": { "relationshipType": "Juridical", "id": "13", "href": "http://serverlocation:port/partyManagement/organization/13", "validFor": { "startDateTime": "2013-04-19T16:42:23.0Z", "endDateTime": "2013-06-19T00:00:00.0Z" } }, "organizationChildRelationship": { "relationshipType": "Juridical", "id": "16", "href": "http://serverlocation:port/partyManagement/organization/16", "validFor": { "startDateTime": "2013-04-19T16:42:23.0Z", "endDateTime": "2013-06-19T00:00:00.0Z" } }, "contactMedium": [ { "type": "Email", "validFor": { "startDateTime": "2013-04-19T16:42:23.0Z" }, "medium": { "emailAddress": "[email protected]" } }, { "type": "PostalAddress", "validFor": { "startDateTime": "2013-04-19T16:42:23.0Z" }, "medium": { "city": "Wien", "country": "Austria", "postcode": "1020", "stateOrProvince": "Quebec", "street1": "Lassallestrasse7", "street2": "" } }, { "type": "TelephoneNumber", "validFor": { "startDateTime": "2013-04-19T16:42:23.0Z" }, "medium": { "type": "mobile", "number": "+436641234567" } }, { "preferred": true, "type": "TelephoneNumber", "validFor": { "startDateTime": "2013-04-19T16:42:23.0Z" }, "medium": { "type": "business", "number": "+436641234567" } } ] } |
PUT partyManagement/individual/{ID}
Description :
- Allows to overwrite an existing individual entry in the party repository
- The resource is a managed entity
Behavior :
- Standard behavior and response codes for PUT operations
Example : Update John Smith (identified by 'i42') : full update
REQUEST |
PUT partyManagement/individual/i42 Content-type: application/json { "id": "i42", "href": "http://serverlocation:port/partyManagement/individual/i42", "gender": "male", "placeOfBirth": "http://goo.gl/maps/l8F9L", "countryOfBirth": "Austria", "nationality": "Canadian", "maritalStatus": "never married", "disability": [ { "disability": "blind" } ], "birthDate": "1961-03-05T00:00:00.0Z", "characteristic": [ { "name": "hobby", "value": "hockey" }, { "name": "", "value": "" } ], "title": "", "givenName": "John", "familyName": "Smith", "middleName": "", "fullName": "", "formattedName": "", "otherName": [ { "title": "", "givenName": "", "familyName": "", "middleName": "", "fullName": "", "formattedName": "", "validFor": { "startDateTime": "2013-04-19T16:42:23.0Z", "endDateTime": "2013-06-19T00:00:00.0Z" } } ], "location": "http://goo.gl/maps/l8F9L", "status": "Initialized", "individualIdentification": [ { "type": "Passport", "identificationId": "73736625252", "issuingAuthority": "", "issuingDate": "2013-06-19T00:00:00.0Z" }, { "type": "SocialSecurityNumber", "identificationId": "33636363", "issuingAuthority": "", "issuingDate": "2013-06-19T00:00:00.0Z" } ], "externalReference": [ { "href": "http://facebook.com/17263635", "type": "FacebookID" }, { "href": "http://google.com/17263635", "type": "GoogleID" } ], "relatedParty": [ { "id": "1", "href": "http://serverlocation:port/partyManagement/organization/1", "role": "Employee", "name": "Richard Cole", "validFor": { "startDateTime": "2013-04-19T16:42:23.0Z", "endDateTime": "2013-06-19T00:00:00.0Z" } } ], "contactMedium": [ { "type": "Email", "validFor": { "startDateTime": "2013-04-19T16:42:23.0Z" }, "medium": { "emailAddress": "[email protected]" } }, { "type": "PostalAddress", "validFor": { "startDateTime": "2013-04-19T16:42:23.0Z" }, "medium": { "city": "Wien", "country": "Austria", "postcode": "1020", "stateOrProvince": "Quebec", "street1": "Lassallestrasse7", "street2": "" } }, { "type": "TelephoneNumber", "validFor": { "startDateTime": "2013-04-19T16:42:23.0Z" }, "medium": { "type": "mobile", "number": "+436641234567" } }, { "preferred": true, "type": "TelephoneNumber", "validFor": { "startDateTime": "2013-04-19T16:42:23.0Z" }, "medium": { "type": "business", "number": "+436641234567" } } ] } |
RESPONSE |
201 Content-Type: application/json { "id": "i42", "href": "http://serverlocation:port/partyManagement/individual/i42", "gender": "male", "placeOfBirth": "http://goo.gl/maps/l8F9L", "countryOfBirth": "Austria", "nationality": "Canadian", "maritalStatus": "never married", "disability": [ { "disability": "blind" } ], "birthDate": "1961-03-05T00:00:00.0Z", "characteristic": [ { "name": "hobby", "value": "hockey" }, { "name": "", "value": "" } ], "title": "", "givenName": "John", "familyName": "Smith", "middleName": "", "fullName": "", "formattedName": "", "otherName": [ { "title": "", "givenName": "", "familyName": "", "middleName": "", "fullName": "", "formattedName": "", "validFor": { "startDateTime": "2013-04-19T16:42:23.0Z", "endDateTime": "2013-06-19T00:00:00.0Z" } } ], "location": "http://goo.gl/maps/l8F9L", "status": "Initialized", "individualIdentification": [ { "type": "Passport", "identificationId": "73736625252", "issuingAuthority": "", "issuingDate": "2013-06-19T00:00:00.0Z" }, { "type": "SocialSecurityNumber", "identificationId": "33636363", "issuingAuthority": "", "issuingDate": "2013-06-19T00:00:00.0Z" } ], "externalReference": [ { "href": "http://facebook.com/17263635", "type": "FacebookID" }, { "href": "http://google.com/17263635", "type": "GoogleID" } ], "relatedParty": [ { "id": "1", "href": "http://serverlocation:port/partyManagement/organization/1", "role": "Employee", "name": "Richard Cole", "validFor": { "startDateTime": "2013-04-19T16:42:23.0Z", "endDateTime": "2013-06-19T00:00:00.0Z" } } ], "contactMedium": [ { "type": "Email", "validFor": { "startDateTime": "2013-04-19T16:42:23.0Z" }, "medium": { "emailAddress": "[email protected]" } }, { "type": "PostalAddress", "validFor": { "startDateTime": "2013-04-19T16:42:23.0Z" }, "medium": { "city": "Wien", "country": "Austria", "postcode": "1020", "stateOrProvince": "Quebec", "street1": "Lassallestrasse7", "street2": "" } }, { "type": "TelephoneNumber", "validFor": { "startDateTime": "2013-04-19T16:42:23.0Z" }, "medium": { "type": "mobile", "number": "+436641234567" } }, { "preferred": true, "type": "TelephoneNumber", "validFor": { "startDateTime": "2013-04-19T16:42:23.0Z" }, "medium": { "type": "business", "number": "+436641234567" } } ] } |
PUT partyManagement/organization/{ID}
Description :
- Allows to overwrite an existing organization entry in the party repository
- The resource is a managed entity
Behavior :
Standard behavior and response codes for PUT operations
REQUEST |
PUT /partyManagement/organization/128 Content-type: application/json { "id": "128", "href": "http://serverlocation:port/partyManagement/organization/128", "isLegalEntity": true, "type": "Company", "existsDuring": { "startDate": "2013-04-19T16:42:23.0Z" }, "tradingName": "Telekom", "nameType": "Co.", "status": "Initialized", "otherName": { "nameType": "Co.", "tradingName": "Orange", "validFor": { "startDateTime": "2013-04-19T16:42:23.0Z", "endDateTime": "2013-06-19T00:00:00.0Z" } }, "characteristic": { "name": "industry", "value": "telecom" }, "organizationIdentification": { "type": "CompanyRegistrationNumber", "identificationId": "374748328", "issuingAuthority": "", "issuingDate": "2013-06-19T00:00:00.0Z", "validFor": { "startDateTime": "2013-04-19T16:42:23.0Z", "endDateTime": "2013-06-19T00:00:00.0Z" } }, "externalReference": [ { "href": "http://facebook.com/17263635", "type": "FacebookID" }, { "href": "http://google.com/17263635", "type": "GoogleID" } ], "relatedParty": { "id": "1", "href": "http://serverlocation:port/partyManagement/organization/12", "role": "Vendor", "name": "Richard Cole", "validFor": { "startDateTime": "2013-04-19T16:42:23.0Z", "endDateTime": "2013-06-19T00:00:00.0Z" } }, "organizationParentRelationship": { "relationshipType": "Juridical", "id": "13", "href": "http://serverlocation:port/partyManagement/organization/13", "validFor": { "startDateTime": "2013-04-19T16:42:23.0Z", "endDateTime": "2013-06-19T00:00:00.0Z" } }, "organizationChildRelationship": { "relationshipType": "Juridical", "id": "16", "href": "http://serverlocation:port/partyManagement/organization/16", "validFor": { "startDateTime": "2013-04-19T16:42:23.0Z", "endDateTime": "2013-06-19T00:00:00.0Z" } }, "contactMedium": [ { "type": "Email", "validFor": { "startDateTime": "2013-04-19T16:42:23.0Z" }, "medium": { "emailAddress": "[email protected]" } }, { "type": "PostalAddress", "validFor": { "startDateTime": "2013-04-19T16:42:23.0Z" }, "medium": { "city": "Wien", "country": "Austria", "postcode": "1020", "stateOrProvince": "Quebec", "street1": "Lassallestrasse7", "street2": "" } }, { "type": "TelephoneNumber", "validFor": { "startDateTime": "2013-04-19T16:42:23.0Z" }, "medium": { "type": "mobile", "number": "+436641234567" } }, { "preferred": true, "type": "TelephoneNumber", "validFor": { "startDateTime": "2013-04-19T16:42:23.0Z" }, "medium": { "type": "business", "number": "+436641234567" } } ] } |
RESPONSE |
201 Content-Type: application/json { JSON Resource Representation with all attributes } |












PATCH partyManagement/individual/{ID}
This Uniform Contract operation is used to partially update the representation of an individual.
Description:
- Patch operation can be used partially update one or more individual
- The resource represents a managed entity or a collection
- The identifier is a string that can consist of numbers, not necessarily alphanumeric
Behavior:
- Return Status Codes:
- Returns HTTP/1.1 status code 201 if individual was updated successfully
- 400 – Bad Request Error
- 404 - If no record was found for the supplied criteria
- 500 - The server encountered an unexpected condition which prevented it from fulfilling the request
Patchable attributes for an individual:
Attribute name | Patchable | Rule |
id | N | |
gender | Y | |
placeOfBirth | N | |
countryOfBirth | Y | |
nationality | Y | |
maritalStatus | Y | |
disability | Y | |
birthDate | N | |
deathDate | Y | |
characteristic | Y | |
title | Y | |
givenName | Y | |
familyName | Y | |
middleName | Y | |
fullName | Y | |
formattedName | Y | |
otherName | Y | |
location | Y | |
individualIdentification | Y | |
externalReference | Y | |
relatedParty | Y | |
contactMedium | Y | |
Further document any rules that must be implemented when patching attributes.
Rule name | Rule/Pre Condition/Side Effects/Post Conditions |
disability | disability is mandatory |
characteristic | name and value are mandatory |
organizationIdentification | type and identification id must be set |
externalReference | referenceType and reference must be set |
relatedParty | role and party are mandatory startDateTime is not mandatory but has a default value -> it is set to sysdate by default |
xxxRelationship | relationshipType and href are mandatory |
Example : Update John Doe (identified with '11') : he is updating his marital status.
REQUEST |
PATCH partyManagement/individual/11 Content-type: application/json { "maritalStatus": "married" } |
RESPONSE |
201 Content-Type: application/json { JSON resource representation with all attributes including the changed one See individual resource model for details } |
Example : Update John Doe (identified with '11') : he is joining an organization that is already stored in the party referential.
REQUEST |
PATCH partyManagement/individual/11 Content-type: application/json-patch+json { "op": "add", "path": "/relatedParty", "value": { "id": "1", "href": "http://serverlocation:port/partyManagement/organization/1", "role": "Employee", "validFor": { "startDateTime": "2013-04-19T16:42:23-04:00", "endDateTime": "" } } } |
RESPONSE |
201 Content-Type: application/json { JSON resource representation with all attributes including the changed one See individual resource model for details } |
PATCH partyManagement/organization/{ID}
This Uniform Contract operation is used to partially update the representation of an organization
Description:
- Patch operation can be used partially update one or more organizations
- The resource represents a managed entity or a collection
- The identifier is a string that can consist of numbers, not necessarily alphanumeric
Behavior:
- Return Status Codes:
- Returns HTTP/1.1 status code 201 if organization was updated successfully
- 400 – Bad Request Error
- 404 - If no record was found for the supplied criteria
- 500 - The server encountered an unexpected condition which prevented it from fulfilling the request
Patchable attributes for an organization:
Attribute name | Patchable | Rule |
id | N | |
isLegalEntity | Y | |
type | Y | |
existsDuring | Y | |
tradingName | Y | |
nameType | Y | |
otherName | Y | |
characteristic | Y | |
organizationIdentification | Y | |
externalReference | Y | |
relatedParty | Y | |
organizationParentRelationship | Y | |
organizationChildRelationship | Y | |
contactMedium | Y | |
Further document any rules that must be implemented when patching attributes.
Rule name | Rule/Pre Condition/Side Effects/Post Conditions |
characteristic Patching Mandatory Values | Name and value |
organizationIdentification Patching Mandatory Values | Type and identificationId |
externalReference Patching Mandatory Values | referenceType and reference |
relatedParty Patching Mandatory Values | Role and party |
relatedParty Patching Default Values | startDateTime is not mandatory is set to sysdate by default |
Example : Example of an organization structure which is changing : IT and Network were previously separated and a new entity was created to merge these two entities (IT&N)
We describe 2 PATCH operations here under :
- PATCH IT entity to tag it as former
- PATCH main organization to change the organization structure (children links)
Organization (id : 131)
IT (id : 1311) Network (id : 1312) IT&N (id : 1319)
We assume that IT&N is already created, and Network entity has been patched.
PATCH of the IT entity :
REQUEST |
PATCH partyManagement/organization/1311 Content-type: application/json { "id": "1311", "href": " http://serverlocation:port/partyManagement/organization/1311", "existsDuring": { "endDate": "2013-04-19T16:42:23-04:00" } } |
RESPONSE |
201 Content-Type: application/json { JSON resource representation with all attributes including the changed one See individual resource model for details } |
PATCH of the Organization top entity : set the relationships endDate for IT & Network relationships, and creation of a new relationship with IT&N
REQUEST |
PATCH partyManagement/organization/131 Content-type: application/json-patch+json [ { "op": "replace", "path": "/organizationChildRelationship/1", "value": { "relationshipType": "Juridical", "id": "1311", "href": "http://serverlocation:port/partyManagement/organization/1311", "validFor": { "startDateTime": "2001-04-19T16:42:23-04:00", "endDateTime": "2013-04-19T16:42:23-04:00" } } }, { "op": "replace", "path": "/organizationChildRelationship/2", "value": { "relationshipType": "Juridical", "id": "1311", "href": "http: //serverlocation: port/partyManagement/organization/1312", "validFor": { "startDateTime": "2001-04-19T16: 42: 23-04: 00", "endDateTime": "2013-04-19T16:42:23-04:00" } } }, { "op": "add", "path": "/organizationChildRelationship", "value": { "relationshipType": "Juridical", "id": "1319", "href": "http: //serverlocation: port/partyManagement/organization/1319", "validFor": { "startDateTime": "2013-04-19T16:42:23-04:00", "endDateTime": "" } } } ] |
RESPONSE |
201 Content-Type: application/json { JSON resource representation with all attributes including the changed one See individual resource model for details } |
POST partyManagement/individual
This operation is used to create an individual.
- The identifier is a string that can consist of numbers, not necessarily alphanumeric
- The mandatory element(s) is/are
When using following elements there are some mandatory attributes within each element:
- Within "disability"
- Within "characteristic"
- Within "organizationIdentification"
- Within "externalReference"
- Within "relatedParty"
- Role
- Party
- startDateTime -> not mandatory is set to sysdate by default
- Within "xxxRelationship"
- relationshipType
- ref
- startDateTime -> not mandatory is set to sysdate by default
- The id is generated automatically
Behavior:
- Return Status Codes:
- 201 – Individual create successfully
- 400 – Bad Request Error
- 500 - The server encountered an unexpected condition which prevented it from fulfilling the request
Attribute name | Mandatory | Default | Rule |
id | N | Automatically generated | If not given, the id is generated by the system. It is also possible to add an ID in the POST request, which is then used |
gender | N | | |
placeOfBirth | N | | |
countryOfBirth | N | | |
nationality | N | | |
maritalStatus | N | | |
disability | N | | |
birthDate | N | | |
deathDate | N | | |
characteristic | N | | |
title | N | | |
givenName | Y | | |
familyName | Y | | |
middleName | N | | |
fullName | N | | |
formattedName | N | | |
otherName | N | | |
location | N | | |
individualIdentification | N | | |
externalReference | N | | |
relatedParty | N | | |
contactMedium | N | | |
Further specify any rules on the creation of the entity
Rule name | Rule/Pre Condition/Side Effects/Post Conditions |
disability | disability is mandatory |
characteristic | name and value are mandatory |
organizationIdentification | type and identification id must be set |
externalReference | referenceType and reference must be set |
relatedParty | role and party are mandatory startDateTime is not mandatory but has a default value -> it is set to sysdate by default |
xxxRelationship | relationshipType and ref are mandatory |
Example : creation of an individual named John Doe
REQUEST |
POST partyManagement/individual Content-type: application/json { "gender": "male", "placeOfBirth": "http://goo.gl/maps/l8F9L", "countryOfBirth": "Austria", "nationality": "Canadian", "maritalStatus": "never married", "disability": [ { "disability": "blind" } ], "birthDate": "2014-03-05", "characteristic": [ { "name": "hobby", "value": "hockey" } ], "title": "Dr", "givenName": "John", "familyName": "Doe", "location": "http://goo.gl/maps/l8F9L", "individualIdentification": [ { "type": "Passport", "identificationId": "73736625252", "issuingAuthority": "", "issuingDate": "2013-06-19T00:00:00-04:00" } ], "externalReference": [ { "href": "http://facebook.com/17263635", "type": "FacebookID" } ], "contactMedium": [ { "type": "Email", "validFor": { "startDateTime": "2013-04-19T16:42:23-04:00", "endDateTime": "" }, "medium": { "emailAddress": "[email protected]" } }, { "type": "PostalAddress", "validFor": { "startDateTime": "2013-04-19T16:42:23-04:00", "endDateTime": "" }, "medium": { "street1": "Lassallestrasse7", "street2": "", "postcode": "1020", "stateOrProvince": "Quebec", "city": "Wien", "country": "Austria" } }, { "type": "TelephoneNumber", "validFor": { "startDateTime": "2013-04-19T16:42:23-04:00", "endDateTime": "" }, "medium": { "type": "mobile", "number": "+436641234567" } }, { "preferred": true, "type": "TelephoneNumber", "validFor": { "startDateTime": "2013-04-19T16:42:23-04:00", "endDateTime": "" }, "medium": { "type": "business", "number": "+436641234567" } } ] } |
RESPONSE |
201 Content-Type: application/json { "id": "11", "href": "http://serverlocation:port/partyManagement/individual/11", "gender": "male", "placeOfBirth": "http://goo.gl/maps/l8F9L", "countryOfBirth": "Austria", "nationality": "Canadian", "maritalStatus": "never married", "disability": [ { "disability": "blind" } ], "birthDate": "2014-03-05", "characteristic": [ { "name": "hobby", "value": "hockey" } ], "title": "Dr", "givenName": "John", "familyName": "Doe", "location": "http://goo.gl/maps/l8F9L", "individualIdentification": [ { "type": "Passport", "identificationId": "73736625252", "issuingAuthority": "", "issuingDate": "2013-06-19T00:00:00-04:00" } ], "externalReference": [ { "href": "http://facebook.com/17263635", "type": "FacebookID" } ], "contactMedium": [ { "type": "Email", "validFor": { "startDateTime": "2013-04-19T16:42:23-04:00", "endDateTime": "" }, "medium": { "emailAddress": "[email protected]" } }, { "type": "PostalAddress", "validFor": { "startDateTime": "2013-04-19T16:42:23-04:00", "endDateTime": "" }, "medium": { "street1": "Lassallestrasse7", "street2": "", "postcode": "1020", "stateOrProvince": "Quebec", "city": "Wien", "country": "Austria" } }, { "type": "TelephoneNumber", "validFor": { "startDateTime": "2013-04-19T16:42:23-04:00", "endDateTime": "" }, "medium": { "type": "mobile", "number": "+436641234567" } }, { "preferred": true, "type": "TelephoneNumber", "validFor": { "startDateTime": "2013-04-19T16:42:23-04:00", "endDateTime": "" }, "medium": { "type": "business", "number": "+436641234567" } } ] } |
POST partyManagement/organization
This operation is used to create an organization.
- The identifier is a string that can consist of numbers, not necessarily alphanumeric
- The mandatory element is:
When using following elements there are some mandatory attributes within each element:
- Within "characteristic"
- Within "organizationIdentification"
- Within "externalReference"
- Within "relatedParty"
- Role
- Party
- startDateTime -> not mandatory is set to sysdate by default
- Within "xxxRelationship"
- relationshipType
- ref
- startDateTime -> not mandatory is set to sysdate by default
- The id is generated automatically
Behavior:
- Return Status Codes:
- 201 – organization created successfully
- 400 – Bad Request Error
- 500 - The server encountered an unexpected condition which prevented it from fulfilling the request
Specify the attributes required when an entity is created (and their default values if not):
Attribute name | Mandatory | Default | Rule |
id | N | Automatically generated | If not given, the id is generated by the system. It is also possible to add an ID in the POST request, which is then used |
isLegalEntity | N | | |
type | N | | |
existsDuring | N | | |
tradingName | Y | | |
nameType | N | | |
otherName | N | | |
characteristic | N | | |
organizationIdentification | N | | |
externalReference | N | | |
relatedParty | N | | |
organizationParentRelationship | N | | |
organizationChildRelationship | N | | |
contactMedium | N | | |
Further specify any rules on the creation of the entity
Rule name | Rule/Pre Condition/Side Effects/Post Conditions |
characteristic Patching Mandatory Values | Name and value |
organizationIdentification Patching Mandatory Values | Type and identificationId |
externalReference Patching Mandatory Values | referenceType and reference |
relatedParty Patching Mandatory Values | Role and party |
relatedParty Patching Default Values | startDateTime is not mandatory is set to sysdate by default |
Example : Creation of a new organization, which is an affiliate of the '13' one already created in the party referential.
REQUEST |
POST partyManagement/organization Content-type: application/json { "isLegalEntity": true, "type": "Company", "existsDuring": { "startDate": "2003-04-19T16:42:23-04:00", "endDate": "" }, "tradingName": "Orange Romania", "nameType": "Co.", "organizationIdentification": [ { "type": "CompanyRegistrationNumber", "identificationId": "374748328", "issuingAuthority": "", "issuingDate": "2013-06-19T00:00:00-04:00", "validFor": { "startDateTime": "2013-04-19T16:42:23-04:00", "endDateTime": "2013-06-19T00:00:00-04:00" } } ], "externalReference": [ { "href": "http: //facebook.com/17263635", "type": "FacebookID" } ], "organizationParentRelationship": { "relationshipType": "Juridical", "id": "13", "href": "http: //serverlocation: port/partyManagement/organization/13", "validFor": { "startDateTime": "2013-04-19T16:42:23-04:00", "endDateTime": "" } }, "contactMedium": [ { "type": "Email", "validFor": { "startDateTime": "2013-04-19T16:42:23-04:00", "endDateTime": "" }, "medium": { "emailAddress": "[email protected]" } }, { "type": "PostalAddress", "validFor": { "startDateTime": "2013-04-19T16:42:23-04:00", "endDateTime": "" }, "medium": { "street1": "Lassallestrasse7", "street2": "", "postcode": "1020", "stateOrProvince": "Quebec", "city": "Wien", "country": "Austria" } }, { "type": "TelephoneNumber", "validFor": { "startDateTime": "2013-04-19T16:42:23-04:00", "endDateTime": "" }, "medium": { "type": "mobile", "number": "+436641234567" } }, { "preferred": true, "type": "TelephoneNumber", "validFor": { "startDateTime": "2013-04-19T16:42:23-04:00", "endDateTime": "" }, "medium": { "type": "business", "number": "+436641234567" } } ] } |
RESPONSE |
201 Content-Type: application/json { "id": "44", "href": "http://serverlocation:port/partyManagement/organization/44", "isLegalEntity": true, "type": "Company", "existsDuring": { "startDate": "2003-04-19T16:42:23-04:00", "endDate": "" }, "tradingName": "Orange Romania", "nameType": "Co.", "organizationIdentification": [ { "type": "CompanyRegistrationNumber", "identificationId": "374748328", "issuingAuthority": "", "issuingDate": "2013-06-19T00:00:00-04:00", "validFor": { "startDateTime": "2013-04-19T16:42:23-04:00", "endDateTime": "2013-06-19T00:00:00-04:00" } } ], "externalReference": [ { "href": "http: //facebook.com/17263635", "type": "FacebookID" } ], "organizationParentRelationship": { "relationshipType": "Juridical", "id": "13", "href": "http: //serverlocation: port/partyManagement/organization/13", "validFor": { "startDateTime": "2013-04-19T16:42:23-04:00", "endDateTime": "" } }, "contactMedium": [ { "type": "Email", "validFor": { "startDateTime": "2013-04-19T16:42:23-04:00", "endDateTime": "" }, "medium": { "emailAddress": "[email protected]" } }, { "type": "PostalAddress", "validFor": { "startDateTime": "2013-04-19T16:42:23-04:00", "endDateTime": "" }, "medium": { "street1": "Lassallestrasse7", "street2": "", "postcode": "1020", "stateOrProvince": "Quebec", "city": "Wien", "country": "Austria" } }, { "type": "TelephoneNumber", "validFor": { "startDateTime": "2013-04-19T16:42:23-04:00", "endDateTime": "" }, "medium": { "type": "mobile", "number": "+436641234567" } }, { "preferred": true, "type": "TelephoneNumber", "validFor": { "startDateTime": "2013-04-19T16:42:23-04:00", "endDateTime": "" }, "medium": { "type": "business", "number": "+436641234567" } } ] } |
DELETE partyManagement/individual/{ID} or /organization/{ID}
Only useful and allowed for administration matters
REQUEST |
DELETE partyManagement/individual/11 |
RESPONSE |
200 |
POST partyManagement/importJob
ImportJob Tasks are created as resources.
The ImportJob is attached to the URL of the root resource where the content of the file specified by the ImportJob will be applied.
For example to apply the content of the import file located at ftp://ftp.myParty.com/party/54 to the partyManagement root.
REQUEST |
POST ../partyManagement/importJob Content-type: application/json { "url": "ftp://ftp.myParty.com/party/54" } |
RESPONSE |
201 Content-Type: application/json Location: ../partyManagement/importJob/554 { "id": "54", "href": "http:/api/partyManagement/importJob/54", "status": "running", "path": "partyManagement/", "content-type": "application/json", "errorLog": "", "creationDate": "2013-04-19T16:42:23-04:00", "url": "ftp://ftp.myParty.com/party/54" } |
POST partyManagement/exportJob
ExportJob Tasks are created as resources.
The ExportJob is attached to a specific resource acting as the root for the collection of resources to be streamed to a File.
An ExportJob can be attached to a specific Resource in the Party Management application or may be attached to the Individual or Organization collections
- ../partyManagement/exportJob
Export all the resources within partyManagement subject to query and path assignments.
- ../partyManagement/individual/exportJob
Export all the individual resources within partyManagement subject to query and path assignments.
For example:
REQUEST |
POST ../partyManagement/exportJob Content-type: application/json { } |
RESPONSE |
201 Content-Type: application/json Location: ../partyManagement/exportJob/54 { "id": "54", "href": "http:/api/catalogManagement/exportJob/54", "status": "running", "path": "partyManagement/", "content-type": "application/json", "errorLog": "", "creationDate": "2013-04-19T16:42:23-04:00", "completionDate": "2013-04-21T16:42:23-04:00", "url": "ftp://ftp.myParty.com/party/54" } |
GET partyManagement/exportJob
ExportJob resources can be found under the API/exportJob collection and may be retrieved using the normal GET constructs.
For example:
REQUEST |
GET ../partyManagement/exportJob/54 Content-type: application/json { } |
RESPONSE |
200 Content-Type: application/json { "id": "54", "href": "http:/api/catalogManagement/exportJob/54", "status": "running", "path": "partyManagement/", "content-type": "application/json", "errorLog": "", "creationDate": "2013-04-19T16:42:23-04:00", "completionDate": "2013-04-21T16:42:23-04:00", "url": "ftp://ftp.myParty.com/party/54" } |
GET partyManagement/IMPORTJob
ImportJob resources can be found under the API/importJob collection and may be retrieved using the normal GET constructs.
For example:
REQUEST |
GET ../partyManagement/importJob/54 Content-type: application/json { } |
RESPONSE |
200 Content-Type: application/json { "id": "54", "href": "http:/api/catalogManagement/importJob/54", "status": "running", "path": "partyManagement/", "content-type": "application/json", "errorLog": "", "creationDate": "2013-04-19T16:42:23-04:00", "completionDate": "2013-04-21T16:42:23-04:00", "url": "ftp://ftp.myParty.com/party/54" } |
© TM Forum 2015. All Rights Reserved