Contract Management API
{ http://soa.com/uri/products/ContractsManager/wsdl/1.0 } ContractAdminService
The API used to manage PM contracts
GET/contractsFetch contracts for the given criteria.
Fetch contracts based on given provider service or provider organization or consumer organization.
Request:
GET /rest/contracts?providerOrg=uddi:f005b0b2-1079-11e5-a330-a83ecc4e96f2 HTTP/1.1
Response:
HTTP/1.1 200 OK
Content-Type: application/xml
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<ns2:Contracts ...">
<ns2:ContractInfo Key="ca58bd4d-c59d-11e7-80a1-ff582ddf16f0:1014" Name="Contract1" Anonymous="false" State="Active">
<ns5:Description>Contract One</ns5:Description>
<ns5:ProviderOrganizationKey>uddi:c6f30e8d-c576-11e7-80a1-ff582ddf16f0</ns5:ProviderOrganizationKey>
<ns5:ConsumerOrganizationKey>uddi:71a538c8-c59d-11e7-80a1-ff582ddf16f0</ns5:ConsumerOrganizationKey>
<ns1:EffectiveDateTimes>
<ns1:StartDateTime>
<ns1:DateTime>2017-11-09T14:31:00-08:00</ns1:DateTime>
<ns1:TimezoneName>America/Los_Angeles</ns1:TimezoneName>
</ns1:StartDateTime>
<ns1:Expire>false</ns1:Expire>
</ns1:EffectiveDateTimes>
<ns5:ContractVersionInfo>
<ns5:MetadataVersion>1</ns5:MetadataVersion>
<ns5:ActiveMetadataVersion>1</ns5:ActiveMetadataVersion>
</ns5:ContractVersionInfo>
<ns5:ContractType>service.contract</ns5:ContractType>
</ns2:ContractInfo>
<ns2:ContractInfo Key="d9b5ff74-c59d-11e7-80a1-ff582ddf16f0:1015" Name="Contract2" Anonymous="false" State="Active">
<ns5:Description>Contract Two</ns5:Description>
<ns5:ProviderOrganizationKey>uddi:c6f30e8d-c576-11e7-80a1-ff582ddf16f0</ns5:ProviderOrganizationKey>
<ns5:ConsumerOrganizationKey>uddi:b8c401a9-c59d-11e7-80a1-ff582ddf16f0</ns5:ConsumerOrganizationKey>
<ns1:EffectiveDateTimes>
<ns1:StartDateTime>
<ns1:DateTime>2017-11-09T14:32:00-08:00</ns1:DateTime>
<ns1:TimezoneName>America/Los_Angeles</ns1:TimezoneName>
</ns1:StartDateTime>
<ns1:Expire>false</ns1:Expire>
</ns1:EffectiveDateTimes>
<ns5:ContractVersionInfo>
<ns5:MetadataVersion>1</ns5:MetadataVersion>
<ns5:ActiveMetadataVersion>1</ns5:ActiveMetadataVersion>
</ns5:ContractVersionInfo>
<ns5:ContractType>service.contract</ns5:ContractType>
</ns2:ContractInfo>
</ns2:Contracts>
Parameters
Reponse
ContractInfo {
EffectiveDateTimesType {
DateTimeZoneType {
ContractVersionInfo {
POST/contractsCreate a contract
Creates a contract in the given organization with given parameters. Note that this operation accepts XML content only in order to accommodate attached policies.
Request:
POST /rest/contracts HTTP/1.1
Content-Type: application/xml
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<ns2:ContractSpec ...>
<ns5:ContractInfo Name="CreatedContract" Anonymous="true" State="Active">
<ns5:Description>Newly Created Contract.</ns5:Description>
<ns5:ProviderOrganizationKey>uddi:f005b0b2-1079-11e5-a330-a83ecc4e96f2</ns5:ProviderOrganizationKey>
<ns1:EffectiveDateTimes>
<ns1:StartDateTime>
<ns1:DateTime>2017-11-03T17:42:03-07:00</ns1:DateTime>
<ns1:TimezoneName>America/Los_Angeles</ns1:TimezoneName>
</ns1:StartDateTime>
<ns1:Expire>false</ns1:Expire>
</ns1:EffectiveDateTimes>
<ns5:ContractVersionInfo>
<ns5:MetadataVersion>1</ns5:MetadataVersion>
<ns5:ActiveMetadataVersion>1</ns5:ActiveMetadataVersion>
</ns5:ContractVersionInfo>
<ns5:ContractType>service.contract</ns5:ContractType>
</ns5:ContractInfo>
<ns5:AddContractContext>
<ns5:Action>@CreateOffer</ns5:Action>
</ns5:AddContractContext>
</ns2:ContractSpec>
Response:
HTTP/1.1 201 Created
Content-Type: application/xml
Location: /rest/contracts/dfde5141-10b2-11e5-93d5-eb4e298f7990:1041
Parameters
ContractInfo {
EffectiveDateTimesType {
DateTimeZoneType {
ContractVersionInfo {
AddContractContext {
SlaAssignment {
SLAPolicy {
${type.name} {}
Rule {
${type.name} {}
Test {
IdentitySet {
IdentitySetInfo {
ResourceSet {
ResourceSetInfo {
Reponse
DELETE/contracts/{key}Remove specified contract
Remove the contract with given key.
Request:
DELETE /rest/contracts/dfde5141-10b2-11e5-93d5-eb4e298f7990:1041 HTTP/1.1
Parameters
Reponse
PUT/contracts/{key}Update contract resource scope.
Change the organization, container, service, operation of a given contract in effect changing the management of contract scope.
Request:
PUT /rest/contracts/9eaa8b14-10b5-11e5-93d5-eb4e298f7990:1042 HTTP/1.1
Content-Type: application/xml
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<ns2:ResourceSet ...>
<ns2:ResourceSetInfo Name="CreatedContract" Anonymous="true" State="Active">
<ns5:ResourceSetName>My Resourceset</ns5:ResourceSetName>
</ns2:ResourceSetInfo>
<ns6:OrganizationKey>uddi:f005b0b2-1079-11e5-a330-a83ecc4e96f2</ns6:OrganizationKey>
<ns6:ContainerKey>nd3845</ns6:ContainerKey>
<ns6:ServiceKey>uddi:a06434c0-1122-11e5-93d5-eb4e298f7990</ns6:ServiceKey>
<ns6:OperationKey>a2328c24-1122-11e5-93d5-eb4e298f7990</ns6:OperationKey>
<ns6:ContractKey>9eaa8b14-10b5-11e5-93d5-eb4e298f7990:1042</ns6:ContractKey>
</ns2:ResourceSet>
Response:
HTTP/1.1 200 OK
Parameters
ResourceSetInfo {
Reponse
GET/contracts/{key}Get contract details.
Get contract information based on given key along with policy information based on the include flag given. Note that this operation produces XML content only in order to accommodate attached policies.
Request:
GET /rest/contracts/d92830eb-1125-11e5-93d5-eb4e298f7990:1043?includepolicy=true HTTP/1.1
Response:
HTTP/1.1 200 OK
Content-Type: application/xml
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<ns5:Contract ...">
<ns5:ContractInfo Key="d92830eb-1125-11e5-93d5-eb4e298f7990:1043" Name="MyContract" Anonymous="false" State="Active">
<ns5:Description>My simple contract</ns5:Description>
<ns5:ProviderOrganizationKey>uddi:f3e6bbe6-c334-11e7-9ec8-92c36890cc34</ns5:ProviderOrganizationKey>
<ns5:ConsumerOrganizationKey>uddi:87fb0f0a-c335-11e7-9ec8-81ef6990b923</ns5:ConsumerOrganizationKey>
<ns1:EffectiveDateTimes>
<ns1:StartDateTime>
<ns1:DateTime>2017-11-09T09:50:00-08:00</ns1:DateTime>
<ns1:TimezoneName>America/Los_Angeles</ns1:TimezoneName>
</ns1:StartDateTime>
<ns1:EndDateTime>
<ns1:DateTime>2018-11-09T09:50:00-08:00</ns1:DateTime>
<ns1:TimezoneName>America/Los_Angeles</ns1:TimezoneName>
</ns1:EndDateTime>
<ns1:Expire>true</ns1:Expire>
</ns1:EffectiveDateTimes>
<ns5:ContractVersionInfo>
<ns5:LastModifiedTimestamp>2017-11-09T09:55:57-08:00</ns5:LastModifiedTimestamp>
<ns5:User>Local Domain\administrator</ns5:User>
<ns5:MetadataVersion>1</ns5:MetadataVersion>
<ns5:ActiveMetadataVersion>1</ns5:ActiveMetadataVersion>
</ns5:ContractVersionInfo>
<ns5:ContractType>service.contract</ns5:ContractType>
</ns5:ContractInfo>
<ns5:ContractScope>
<ns1:ServiceKey>uddi:f3e6bbe6-c334-11e7-9ec8-81ef6990b923</ns1:ServiceKey>
</ns5:ContractScope>
<ns5:ConsumerIdentities>
<ns7:OrganizationIdentity>uddi:87fb0f0a-c335-11e7-9ec8-81ef6990b923</ns7:OrganizationIdentity>
</ns5:ConsumerIdentities>
<ns5:PolicyAttachments>
<wsp:Policy xmlns:wsp="http://schemas.xmlsoap.org/ws/2004/09/policy" ... Name="urn:uuid:f76c1d70-c576-11e7-80a1-ff582ddf16f0" visibility="public" wsu:Id="Policy1">
<dns0:SLAEnforcement xmlns:dns0="http://federatedgovernance.org/policy/quota/slaenforcement/1.0">
<dns0:FaultMessage>SLPFault</dns0:FaultMessage>
</dns0:SLAEnforcement>
</wsp:Policy>
</ns5:PolicyAttachments>
</ns5:Contract>
Parameters
Reponse
ContractInfo {
EffectiveDateTimesType {
DateTimeZoneType {
ContractVersionInfo {
Artifacts {
Artifact {
PolicyAttachments {
ResourceSet {
ResourceSetInfo {
IdentitySet {
IdentitySetInfo {
PUT/contracts/{key}/workflowPerform Workflow Action
Performs a workflow action on the contract with the given key. The available workflow actions are based on the current workflow process in use for contracts in the system.
Request:
PUT /rest/contracts/d92830eb-1125-11e5-93d5-eb4e298f7990:1043/workflow HTTP/1.1
Content-Type: application/json
{
"Action" : "Activate Contract",
"Comment" : "Putting contract into production.",
"UserName" : "jdoe"
}
Response:
HTTP/1.1 200 OK