{"openapi":"3.0.4","info":{"title":"Upsert a Custom Entity instance","description":"Insert the Custom Entity if it does not exist or update the Custom Entity with the supplied state if it does exist.","version":"0.0.1"},"servers":[{"url":"https://fbn-prd.lusid.com/api"}],"paths":{"/api/customentities/{entityType}":{"post":{"tags":["CustomEntities"],"summary":"Upsert a Custom Entity instance","description":"Insert the Custom Entity if it does not exist or update the Custom Entity with the supplied state if it does exist.","operationId":"UpsertCustomEntity","parameters":[{"name":"entityType","in":"path","description":"The type of the Custom Entity to be created. An entityType can be created using the \"CreateCustomEntityDefinition\" endpoint for CustomEntityDefinitions.","required":true,"schema":{"maxLength":65,"minLength":1,"type":"string"}}],"requestBody":{"description":"The payload describing the Custom Entity instance.","content":{"application/json-patch+json":{"schema":{"$ref":"/docs/api/lusid/schemas.json#/components/schemas/CustomEntityRequest"},"example":{"displayName":"Portfolio Access Denied","description":"User cannot access the portfolio","identifiers":[{"identifierScope":"someScope","identifierType":"supportTicketId","identifierValue":"xyz123pqr"}],"fields":[{"name":"clientId","value":"AcmeLtd"},{"name":"issueDescription","value":"I can't access this portfolio","effectiveFrom":"2023-03-03T09:00:00.0000000+00:00"}],"properties":{"CustomEntity/someScope/somePropertyName":{"key":"CustomEntity/someScope/somePropertyName","value":{"labelValue":"some-property-value"},"effectiveFrom":"2018-06-18T09:00:00.0000000+00:00"}}}},"application/json":{"schema":{"$ref":"/docs/api/lusid/schemas.json#/components/schemas/CustomEntityRequest"},"example":{"displayName":"Portfolio Access Denied","description":"User cannot access the portfolio","identifiers":[{"identifierScope":"someScope","identifierType":"supportTicketId","identifierValue":"xyz123pqr"}],"fields":[{"name":"clientId","value":"AcmeLtd"},{"name":"issueDescription","value":"I can't access this portfolio","effectiveFrom":"2023-03-03T09:00:00.0000000+00:00"}],"properties":{"CustomEntity/someScope/somePropertyName":{"key":"CustomEntity/someScope/somePropertyName","value":{"labelValue":"some-property-value"},"effectiveFrom":"2018-06-18T09:00:00.0000000+00:00"}}}},"text/json":{"schema":{"$ref":"/docs/api/lusid/schemas.json#/components/schemas/CustomEntityRequest"},"example":{"displayName":"Portfolio Access Denied","description":"User cannot access the portfolio","identifiers":[{"identifierScope":"someScope","identifierType":"supportTicketId","identifierValue":"xyz123pqr"}],"fields":[{"name":"clientId","value":"AcmeLtd"},{"name":"issueDescription","value":"I can't access this portfolio","effectiveFrom":"2023-03-03T09:00:00.0000000+00:00"}],"properties":{"CustomEntity/someScope/somePropertyName":{"key":"CustomEntity/someScope/somePropertyName","value":{"labelValue":"some-property-value"},"effectiveFrom":"2018-06-18T09:00:00.0000000+00:00"}}}},"application/*+json":{"schema":{"$ref":"/docs/api/lusid/schemas.json#/components/schemas/CustomEntityRequest"},"example":{"displayName":"Portfolio Access Denied","description":"User cannot access the portfolio","identifiers":[{"identifierScope":"someScope","identifierType":"supportTicketId","identifierValue":"xyz123pqr"}],"fields":[{"name":"clientId","value":"AcmeLtd"},{"name":"issueDescription","value":"I can't access this portfolio","effectiveFrom":"2023-03-03T09:00:00.0000000+00:00"}],"properties":{"CustomEntity/someScope/somePropertyName":{"key":"CustomEntity/someScope/somePropertyName","value":{"labelValue":"some-property-value"},"effectiveFrom":"2018-06-18T09:00:00.0000000+00:00"}}}}},"required":true},"responses":{"200":{"description":"The upserted custom entity instance","content":{"application/json":{"schema":{"$ref":"/docs/api/lusid/schemas.json#/components/schemas/CustomEntityResponse"},"example":{"href":"https://myco.lusid.com/api/api/customentities/~SupportTicket","entityType":"~SupportTicket","version":{"effectiveFrom":"0001-01-01T00:00:00.0000000+00:00","asAtDate":"2022-03-02T09:00:00.0000000+00:00"},"displayName":"Portfolio Access Denied","description":"User cannot access the portfolio","identifiers":[{"identifierScope":"someScope","identifierType":"supportTicketId","identifierValue":"xyz123pqr","effectiveFrom":"0001-01-01T00:00:00.0000000+00:00","effectiveUntil":"9999-12-31T23:59:59.9999999+00:00"}],"fields":[{"name":"clientId","value":"AcmeLtd","effectiveFrom":"0001-01-01T00:00:00.0000000+00:00","effectiveUntil":"9999-12-31T23:59:59.9999999+00:00"},{"name":"issueDescription","value":"I can't access this portfolio","effectiveFrom":"2022-03-03T09:00:00.0000000+00:00","effectiveUntil":"9999-12-31T23:59:59.9999999+00:00"}],"relationships":[]}},"text/plain":{"schema":{"$ref":"/docs/api/lusid/schemas.json#/components/schemas/CustomEntityResponse"},"example":{"href":"https://myco.lusid.com/api/api/customentities/~SupportTicket","entityType":"~SupportTicket","version":{"effectiveFrom":"0001-01-01T00:00:00.0000000+00:00","asAtDate":"2022-03-02T09:00:00.0000000+00:00"},"displayName":"Portfolio Access Denied","description":"User cannot access the portfolio","identifiers":[{"identifierScope":"someScope","identifierType":"supportTicketId","identifierValue":"xyz123pqr","effectiveFrom":"0001-01-01T00:00:00.0000000+00:00","effectiveUntil":"9999-12-31T23:59:59.9999999+00:00"}],"fields":[{"name":"clientId","value":"AcmeLtd","effectiveFrom":"0001-01-01T00:00:00.0000000+00:00","effectiveUntil":"9999-12-31T23:59:59.9999999+00:00"},{"name":"issueDescription","value":"I can't access this portfolio","effectiveFrom":"2022-03-03T09:00:00.0000000+00:00","effectiveUntil":"9999-12-31T23:59:59.9999999+00:00"}],"relationships":[]}},"text/json":{"schema":{"$ref":"/docs/api/lusid/schemas.json#/components/schemas/CustomEntityResponse"},"example":{"href":"https://myco.lusid.com/api/api/customentities/~SupportTicket","entityType":"~SupportTicket","version":{"effectiveFrom":"0001-01-01T00:00:00.0000000+00:00","asAtDate":"2022-03-02T09:00:00.0000000+00:00"},"displayName":"Portfolio Access Denied","description":"User cannot access the portfolio","identifiers":[{"identifierScope":"someScope","identifierType":"supportTicketId","identifierValue":"xyz123pqr","effectiveFrom":"0001-01-01T00:00:00.0000000+00:00","effectiveUntil":"9999-12-31T23:59:59.9999999+00:00"}],"fields":[{"name":"clientId","value":"AcmeLtd","effectiveFrom":"0001-01-01T00:00:00.0000000+00:00","effectiveUntil":"9999-12-31T23:59:59.9999999+00:00"},{"name":"issueDescription","value":"I can't access this portfolio","effectiveFrom":"2022-03-03T09:00:00.0000000+00:00","effectiveUntil":"9999-12-31T23:59:59.9999999+00:00"}],"relationships":[]}}}},"400":{"description":"The details of the input related failure","content":{"application/json":{"schema":{"$ref":"/docs/api/lusid/schemas.json#/components/schemas/LusidValidationProblemDetails"}},"text/plain":{"schema":{"$ref":"/docs/api/lusid/schemas.json#/components/schemas/LusidValidationProblemDetails"}},"text/json":{"schema":{"$ref":"/docs/api/lusid/schemas.json#/components/schemas/LusidValidationProblemDetails"}}}},"default":{"description":"Error response","content":{"application/json":{"schema":{"$ref":"/docs/api/lusid/schemas.json#/components/schemas/LusidProblemDetails"}}}}},"security":[{"BearerAuth":[]}],"x-fbn-apistatus":"Stable"}}},"components":{"securitySchemes":{"BearerAuth":{"type":"http","scheme":"bearer"}}}}