{"openapi":"3.0.1","info":{"title":"3pdm - 3rd Party Service Domain Manager","description":"<span></span>\n## OVERVIEW\n\n*********************************************\n3rd Party Domain Manager API goal is to provide the ability to create and manage 3rd party services and tenants.\n#### 3PDM APIs perform the following  :\n- Create/provision a tenant for a customer\n- Get details for an existing tenant\n- Create/provision a 3rd party service\n- Modify a 3rd party service\n- Terminate a tenant/service\n*****************************************************","contact":{"name":"3rdPartyServices Devops Team","email":"3pdm@telstra.com"},"version":"1.0.0","x-service-version":"v1.0.0"},"servers":[{"description":"SwaggerHub API Auto Mocking","url":"https://virtserver.swaggerhub.com/GEETHUBRIDGET/3pdm_t2/1.0.0"}],"tags":[{"name":"tenant","description":"API for tenant management"},{"name":"job","description":"API for job details retrieval"}],"paths":{"/3pdm/v1/tenant":{"post":{"tags":["tenant"],"summary":"Creates a tenant","description":"This operation creates a tenant","parameters":[{"name":"Authorization","in":"header","description":"Format: **Bearer** ***access_token***","required":true,"schema":{"type":"string"}},{"name":"X-Correlation-ID","in":"header","description":"UUID. Used for business transaction correlation in the Logs.","schema":{"type":"string"},"required":true}],"requestBody":{"description":"The tenant to be created","content":{"application/json;charset=utf-8":{"schema":{"$ref":"#/components/schemas/TenantRequest"},"example":{"name":"3PTenant","description":"3rd Party Tenant for Consumers","characteristics":[{"name":"country","value":"Singapore"},{"name":"customerIdentifier","value":"<telstra customer identifier>"},{"name":"primaryDomain","value":"abc.onmicrosoft.com"}]}}},"required":true},"responses":{"202":{"description":"Accepted","headers":{"X-Correlation-id":{"description":"UUID. Used for business transaction correlation in the Logs.","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Acknowledgement"},"example":{"id":"e26205f4-e144-4ded-9e64-82ede0b26e33","href":"3pdm/v1/tenant/e26205f4-e144-4ded-9e64-82ede0b26e33","job":{"id":"d26205f4-e144-4ded-9e64-82ede0b26e33","href":"3pdm/v1/job/d26205f4-e144-4ded-9e64-82ede0b26e33"}}}}},"400":{"description":"Bad Request","headers":{"X-Correlation-id":{"description":"UUID. Used for business transaction correlation in the Logs.","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/3pdm/v1/tenant/{tenantId}":{"get":{"tags":["tenant"],"summary":"Retrieves tenant details","description":"This operation retrieves tenant details","parameters":[{"name":"Authorization","in":"header","description":"Format: **Bearer** ***access_token***","required":true,"schema":{"type":"string"}},{"name":"X-Correlation-ID","in":"header","description":"UUID. Used for business transaction correlation in the Logs.","schema":{"type":"string"},"required":true},{"name":"tenantId","in":"path","description":"UUID identifier of tenant","schema":{"type":"string"},"required":true}],"responses":{"200":{"description":"OK","headers":{"X-Correlation-id":{"description":"UUID. Used for business transaction correlation in the Logs.","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TenantResponse"},"examples":{"GET for tenant in active state":{"value":{"name":"3PartyService","id":"e26205f4-e144-4ded-9e64-82ede0b26e33","href":"3pdm/v1/tenant/e26205f4-e144-4ded-9e64-82ede0b26e33","description":"3PartyService Service for Consumers","state":"active","creationDate":"2024-08-01T14:20:54.123Z","characteristics":[{"name":"country","value":"Singapore"},{"name":"customerIdentifier","value":"<telstra customer identifier>"},{"name":"microsoftCustomerId","value":"ff569a8c-1d1f-4e82-852a-830a7472f3a1"},{"name":"primaryDomain","value":"abc.onmicrosoft.com"}]}}}}}},"400":{"description":"Bad Request","headers":{"X-Correlation-id":{"description":"UUID. Used for business transaction correlation in the Logs.","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/3pdm/v1/job/{jobId}":{"get":{"tags":["job"],"summary":"Retrieves job details","description":"This operation retrieves job details","parameters":[{"name":"Authorization","in":"header","description":"Format: **Bearer** ***access_token***","required":true,"schema":{"type":"string"}},{"name":"X-Correlation-ID","in":"header","description":"UUID. Used for business transaction correlation in the Logs.","schema":{"type":"string"},"required":true},{"name":"jobId","in":"path","description":"UUID identifier of job","schema":{"type":"string"},"required":true}],"responses":{"200":{"description":"OK","headers":{"X-Correlation-id":{"description":"UUID. Used for business transaction correlation in the Logs.","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/JobResponse"},"examples":{"GET for successful job":{"value":{"id":"d26205f4-e144-4ded-9e64-82ede0b26e33","href":"3pdm/v1/tenant/d26205f4-e144-4ded-9e64-82ede0b26e33","status":"completed"}},"GET for failed job":{"value":{"id":"d26205f4-e144-4ded-9e64-82ede0b26e33","href":"3pdm/v1/tenant/d26205f4-e144-4ded-9e64-82ede0b26e33","status":"failed","error":{"message":"Tenant creation failed due to duplicate domain name","timestamp":"2024-08-01T14:20:54.123Z"}}}}}}},"400":{"description":"Bad Request","headers":{"X-Correlation-id":{"description":"UUID. Used for business transaction correlation in the Logs.","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}}},"components":{"schemas":{"Characteristics":{"required":["name","value"],"type":"object","properties":{"name":{"type":"string","description":"Name of the characteristic"},"value":{"anyOf":[{"type":"string"}]}},"description":"Describes a given characteristic of an object or entity through a name/value pair."},"Acknowledgement":{"required":["href","id"],"type":"object","properties":{"id":{"type":"string","description":"This should be a UUID created by Domain. Identifier of a Service Instance. Required to be unique. Used in URIs as the identifier of the Service Instance (for modify or delete use cases)."},"href":{"type":"string","description":"Created by Domain. Reference to the Service Instance (useful for delete or modify methods)"},"job":{"$ref":"#/components/schemas/Job"}}},"Job":{"required":["href","id"],"type":"object","properties":{"id":{"type":"string","description":"This should be a UUID to identify the created job."},"href":{"type":"string","description":"Created by Domain. Reference to the created job"}}},"TenantRequest":{"required":["characteristics"],"type":"object","properties":{"description":{"type":"string","description":"Free-text description of the service"},"name":{"type":"string","description":"Name of the service"},"characteristic":{"type":"array","description":"A list of characteristics that characterize this service (ServiceCharacteristic [*]) ","items":{"$ref":"#/components/schemas/Characteristics"}}}},"TenantResponse":{"required":["characteristics","href","state","id"],"type":"object","properties":{"id":{"type":"string","description":"Unique identifier of the service"},"href":{"type":"string","description":"Reference of the service"},"name":{"type":"string","description":"Name of the service"},"description":{"type":"string","description":"Free-text description of the service"},"creationDate":{"type":"string","description":"Date when the service was created (whatever its status)."},"state":{"$ref":"#/components/schemas/StateType"},"characteristic":{"type":"array","description":"A list of characteristics that characterize this service (ServiceCharacteristic [*]) ","items":{"$ref":"#/components/schemas/Characteristics"}}}},"JobResponse":{"required":["id","href","status"],"type":"object","properties":{"id":{"type":"string","description":"Unique identifier of the job"},"href":{"type":"string","description":"Reference of the job"},"status":{"$ref":"#/components/schemas/JobStatusType"},"error":{"$ref":"#/components/schemas/JobError"}}},"JobError":{"required":["message"],"type":"object","properties":{"message":{"type":"string","description":"Contains the error message if job is in failed state"},"timestamp":{"type":"string","description":"Timestamp of the error"}}},"StateType":{"type":"string","description":"Valid values for the lifecycle state of the service","enum":["initial","active","terminated"]},"JobStatusType":{"type":"string","description":"Valid values for the status of a job","enum":["completed","in progress","failed"]},"Error":{"required":["code","reason"],"type":"object","properties":{"code":{"type":"string","description":"Application relevant detail, defined in the API or a common list.","example":"3PDM-0400"},"reason":{"type":"string","description":"Explanation of the reason for the error which can be shown to a client user.","example":"Incorrect or missing mandatory field"}},"description":"A period of time, either as a deadline (endDateTime only) a startDateTime only, or both"}}}}