{"openapi":"3.0.0","paths":{"/api/v1/counterparties":{"get":{"deprecated":true,"operationId":"ApiCounterpartiesController_getCounterparties","parameters":[],"responses":{"200":{"description":"Get Counterparties","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ApiCounterpartiesResponseDto"}}}}},"security":[{"bearer":[]}],"summary":"","tags":["Counterparties"]}},"/api/v1/counterparty/companies":{"get":{"operationId":"ApiCounterpartiesController_getEntityCounterparties","parameters":[{"name":"page","required":false,"in":"query","description":"Number of the page","schema":{"type":"number"}},{"name":"limit","required":false,"in":"query","description":"Number of counterparties returned per page","schema":{"type":"number"}},{"name":"name","required":false,"in":"query","description":"Filter by counterparty company name","schema":{"type":"string"}},{"name":"referenceId","required":false,"in":"query","description":"Filter by counterparty reference ID","schema":{"type":"string"}},{"name":"interval","required":false,"in":"query","description":"Time interval unit for filtering counterparties within specific time frame for the AML \"updatedAt\" field","schema":{"$ref":"#/components/schemas/TimeIntervalEnum"}},{"name":"unit","required":false,"in":"query","description":"Number of units for the time interval (e.g., if interval is \"hour\" and unit is 60, it means within the last 60 hours)","schema":{"minimum":1,"type":"number"}}],"responses":{"200":{"description":"Get Counterparties of category entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ApiCounterpartiesResponseDto"}}}}},"security":[{"bearer":[]}],"tags":["Counterparties"]}},"/api/v1/counterparty/individuals":{"get":{"operationId":"ApiCounterpartiesController_getIndividualCounterparties","parameters":[{"name":"page","required":false,"in":"query","description":"Number of the page","schema":{"type":"number"}},{"name":"limit","required":false,"in":"query","description":"Number of counterparties returned per page","schema":{"type":"number"}},{"name":"name","required":false,"in":"query","description":"Filter by counterparty individual name","schema":{"type":"string"}},{"name":"referenceId","required":false,"in":"query","description":"Filter by counterparty reference ID","schema":{"type":"string"}},{"name":"interval","required":false,"in":"query","description":"Time interval unit for filtering counterparties within specific time frame for the AML \"updatedAt\" field","schema":{"$ref":"#/components/schemas/TimeIntervalEnum"}},{"name":"unit","required":false,"in":"query","description":"Number of units for the time interval (e.g., if interval is \"hour\" and unit is 60, it means within the last 60 hours)","schema":{"minimum":1,"type":"number"}}],"responses":{"200":{"description":"Get Counterparties of category individual","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ApiIndividualCounterpartiesResponseDto"}}}}},"security":[{"bearer":[]}],"tags":["Counterparties"]}},"/api/v1/officers/by-ref/{refId}":{"get":{"operationId":"ApiOfficersController_getOfficerByRefId","parameters":[{"name":"refId","required":true,"in":"path","schema":{"type":"string"}}],"responses":{"200":{"description":"Get an officer by referenceId","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ApiOfficerDto"}}}},"404":{"description":"Officer not found"}},"security":[{"bearer":[]}],"summary":"Get an officer by referenceId","tags":["Officers"]}},"/api/v1/officers/{id}":{"get":{"operationId":"ApiOfficersController_getOfficerById","parameters":[{"name":"id","required":true,"in":"path","schema":{"type":"string"}}],"responses":{"200":{"description":"Get an officer by ID","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ApiOfficerDto"}}}},"404":{"description":"Officer not found"}},"security":[{"bearer":[]}],"summary":"Get an officer by ID","tags":["Officers"]}},"/api/v1/companies/{companyId}/related-companies":{"get":{"operationId":"ApiRelatedCompaniesController_getRelatedCompanies","parameters":[{"name":"companyId","required":true,"in":"path","schema":{"type":"string"}},{"name":"type","required":false,"in":"query","schema":{"enum":["parent","subsidiary"],"type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/RelatedCompanyDto"}}}}},"404":{"description":"Company not found"}},"security":[{"bearer":[]}],"summary":"Get related companies for a company by ID","tags":["Companies"]},"post":{"description":"Pure create: 409 Conflict if a relation already exists for a given item, or if creating it would close an ownership cycle. All-or-nothing — a failing item rolls back the whole batch.","operationId":"ApiRelatedCompaniesController_addRelatedCompanies","parameters":[{"name":"companyId","required":true,"in":"path","schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/PostRelatedCompanyDto"}}}}},"responses":{"201":{"description":"","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/RelatedCompanyDto"}}}}},"404":{"description":"Company not found"},"409":{"description":"Relation already exists, or would create a cycle"}},"security":[{"bearer":[]}],"summary":"Create related company relation(s)","tags":["Companies"]},"put":{"description":"Reconciles the full bidirectional relation set against the given body: matched relations are updated in place (keeping their id), new ones are created (409 if that exact pair already exists, or the write would close a cycle), and existing relations no longer present are removed. All in one transaction.","operationId":"ApiRelatedCompaniesController_replaceRelatedCompanies","parameters":[{"name":"companyId","required":true,"in":"path","schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/PutRelatedCompanyDto"}}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/RelatedCompanyDto"}}}}},"404":{"description":"Company not found"},"409":{"description":"A new item's relation already exists, or would create a cycle"}},"security":[{"bearer":[]}],"summary":"Replace all related company relations, in both directions","tags":["Companies"]}},"/api/v1/companies/{companyId}/related-companies/{relationId}":{"get":{"operationId":"ApiRelatedCompaniesController_getRelatedCompany","parameters":[{"name":"companyId","required":true,"in":"path","schema":{"type":"string"}},{"name":"relationId","required":true,"in":"path","schema":{"type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RelatedCompanyDto"}}}},"404":{"description":"Company or relation not found"}},"security":[{"bearer":[]}],"summary":"Get a single related company relation by id","tags":["Companies"]},"patch":{"description":"Only the supplied fields change; direction and companies are immutable for a given relation id.","operationId":"ApiRelatedCompaniesController_patchRelatedCompany","parameters":[{"name":"companyId","required":true,"in":"path","schema":{"type":"string"}},{"name":"relationId","required":true,"in":"path","schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PatchRelatedCompanyDto"}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RelatedCompanyDto"}}}},"404":{"description":"Company or relation not found"}},"security":[{"bearer":[]}],"summary":"Partially update a related company relation","tags":["Companies"]},"put":{"description":"Full replace of the relation fields — omitted fields are cleared. 404 if the relation does not exist; relation ids are server-generated, so this never creates.","operationId":"ApiRelatedCompaniesController_replaceRelatedCompanyDetails","parameters":[{"name":"companyId","required":true,"in":"path","schema":{"type":"string"}},{"name":"relationId","required":true,"in":"path","schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PatchRelatedCompanyDto"}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RelatedCompanyDto"}}}},"404":{"description":"Company or relation not found"}},"security":[{"bearer":[]}],"summary":"Replace a related company relation","tags":["Companies"]},"delete":{"operationId":"ApiRelatedCompaniesController_removeRelatedCompany","parameters":[{"name":"companyId","required":true,"in":"path","schema":{"type":"string"}},{"name":"relationId","required":true,"in":"path","schema":{"type":"string"}}],"responses":{"204":{"description":""},"404":{"description":"Company or relation not found"}},"security":[{"bearer":[]}],"summary":"Remove a related company relation","tags":["Companies"]}},"/api/v1/companies/{companyId}/related-officers":{"get":{"operationId":"ApiRelatedOfficersController_getRelatedOfficers","parameters":[{"name":"companyId","required":true,"in":"path","schema":{"type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/RelatedOfficerDto"}}}}},"404":{"description":"Company not found"}},"security":[{"bearer":[]}],"summary":"Get related officers for a company by ID","tags":["Companies"]},"post":{"operationId":"ApiRelatedOfficersController_addRelatedOfficers","parameters":[{"name":"companyId","required":true,"in":"path","schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/PostRelatedOfficerDto"}}}}},"responses":{"201":{"description":"","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/RelatedOfficerDto"}}}}},"404":{"description":"Company not found"}},"security":[{"bearer":[]}],"summary":"Add related officer relations","tags":["Companies"]},"put":{"operationId":"ApiRelatedOfficersController_replaceRelatedOfficers","parameters":[{"name":"companyId","required":true,"in":"path","schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/PutRelatedOfficerDto"}}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/RelatedOfficerDto"}}}}},"404":{"description":"Company not found"}},"security":[{"bearer":[]}],"summary":"Replace all related officer relations (clears existing)","tags":["Companies"]}},"/api/v1/sync":{"put":{"description":"A single endpoint for synchronizing multiple companies and\n      related structures with\n      the Avallone platform. The endpoint tries to allow stateless\n      updates in which the caller should not need to know anything about\n      the state of companies in the Avallone platform, but simply provide\n      a list of operations to keep the platform updated with an external\n      platform or model.\n      <br /><br />\n      For this reason we do not use internal IDs to identify objects and\n      strongly advise that all companies are created with and are referred\n      to using the `referenceId`s from the source platform. A reference ID\n      should be immutable, unique and identifiable in both platforms. It can\n      be any string.\n      <br /><br />\n      In cases where a reference ID has not been defined, the name,\n      registration number and type properties can be used to identify companies\n      via the `config.companyIdFields` body parameter.\n      This does, however, put some constraints on actions that can be performed,\n      for instance if a company cannot be unambiguously identified without using\n      name, it will not be possible to rename the company without the reference ID.\n      <br /><br />","operationId":"ApiSyncController_sync","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SyncPayloadDto"},"examples":{"schemaExample":{"summary":"Request Configuration","description":"The `config` property can be used to configure how the request should be interpreted. It is an optional parameter. For more information, please look at the `Schema` tab, which also includes default values","value":"\n{\n  \"config\": {\n    \"companyIdFields\": [\"referenceId\"],\n    \"officerIdFields\": [\"referenceId\"],\n    \"caseIdFields\": [\"referenceId\"],\n    \"cleanup\": false,\n    \"sync\": [\"companies\", \"officers\"],\n    \"saveReferenceId\": false\n  }\n}\n    "},"createCompany":{"summary":"Create or update a company","description":"For companies where a reference ID has been defined upon  creation, using that reference ID in future requests will instead update the existing company","value":"\n{\n  \"companies\": [\n    {\n      \"referenceId\": \"acme-inc\",\n      \"name\": \"Acme Inc\",\n      \"registrationNumber\": \"acme-inc\",\n      \"incorporationCountryCode\": \"DK\"\n    }\n  ]\n}\n    "},"fuzzyUpdate":{"summary":"Update an entity without a reference ID","description":"In cases where we want to update an entity where a reference ID has  not been specified, we need to identify instead by using the `config.companyIdFields` or corresponding prop for the object you want to update property. In this example we're using a combination of `name` and `registrationNumber` to identify a company.<br /><br /><b>Note</b>: Since we're using name to identify the company, this method cannot be used to rename entities. In order to rename an entity, it must have a reference ID","value":"\n{\n  \"config\": {\n    \"companyIdFields\": [\"name\", \"registrationNumber\"]\n  },\n  \"companies\": [\n    {\n      \"name\": \"Acme Inc\",\n      \"registrationNumber\": \"123456789\"\n    }\n  ]\n}\n    "},"updateReferenceId":{"summary":"Update the reference ID of an entity","description":"In order to update the reference ID of an entity, we need to identify the entity using other properties, and setting the config field `saveReferenceId = true`","value":"\n{\n  \"config\": {\n    \"companyIdFields\": [\"name\", \"registrationNumber\"],\n    \"saveReferenceId\": true\n  },\n  \"companies\": [\n    {\n      \"name\": \"Acme Inc\",\n      \"registrationNumber\": \"123456789\",\n      \"referenceId\": \"acme-inc\"\n    }\n  ]\n}\n    "},"createCounterpartyCompany":{"summary":"Create a counterparty company","value":"\n{\n  \"companies\": [\n    {\n      \"referenceId\": \"acme-inc\",\n      \"name\": \"Acme Inc\",\n      \"registrationNumber\": \"acme-inc\",\n      \"incorporationCountryCode\": \"DK\",\n      \"type\": \"counterparty\"\n    }\n  ]\n}\n    "},"deleteCounterpartyCompany":{"summary":"Delete a counterparty company","value":"\n{\n  \"companies\": [\n    {\n      \"referenceId\": \"acme-inc\",\n      \"name\": \"Acme Inc\",\n      \"registrationNumber\": \"acme-inc\",\n      \"incorporationCountryCode\": \"DK\",\n      \"type\": \"counterparty\",\n      \"delete\": true\n    }\n  ]\n}\n    "},"createCompanyWithAddress":{"summary":"Create a company with primary address","value":"\n{\n  \"companies\": [\n    {\n      \"referenceId\": \"acme-inc\",\n      \"name\": \"Acme Inc\",\n      \"registrationNumber\": \"acme-inc\",\n      \"incorporationCountryCode\": \"DK\",\n      \"addresses\": {\n        \"primary\": {\n          \"streetAddress\": \"Elm street\",\n          \"zipCode\": \"2300\",\n          \"city\": \"Copenhagen\",\n          \"countryCode\": \"DK\"\n        }\n      }\n    }\n  ]\n}\n"},"createParentCompanyRelation":{"summary":"Create a parent and child company","value":"\n{\n  \"companies\": [\n    {\n      \"referenceId\": \"acme-inc\",\n      \"name\": \"Acme Inc\",\n      \"registrationNumber\": \"acme-inc\",\n      \"incorporationCountryCode\": \"DK\"\n    },\n    {\n      \"referenceId\": \"wayne-corp\",\n      \"name\": \"Wayne Corp\",\n      \"registrationNumber\": \"wayne-corp\",\n      \"incorporationCountryCode\": \"SE\",\n      \"relatedCompanies\": [\n        {\n          \"referenceId\": \"acme-inc\",\n          \"ownership\": 25\n        }\n      ]\n    }\n  ]\n}\n"},"createCompanyRelation":{"summary":"Create a company relation","description":"Creates company relation. Use details for company roles and reasons, for example when the relation has no ownership structure. Each role must already exist in your tenant.","value":"\n    {\n      \"companies\": [\n        {\n          \"referenceId\": \"wayne-corp\",\n          \"name\": \"Wayne Corp\",\n          \"registrationNumber\": \"wayne-corp\",\n          \"incorporationCountryCode\": \"SE\",\n          \"relatedCompanies\": [\n            {\n              \"referenceId\": \"acme-inc\",\n              \"details\": [\n                { \"role\": \"General Partner\", \"reason\": \"Manages the fund\" },\n                { \"reason\": \"Common management\" }\n              ]\n            }\n          ]\n        }\n      ]\n    }"},"createOfficer":{"summary":"Create an officer","value":"\n{\n  \"companies\": [],\n  \"officers\": [\n    {\n      \"referenceId\": \"john-doe\",\n      \"firstName\": \"John\",\n      \"lastName\": \"Doe\",\n      \"isPep\": false\n    }\n  ]\n}\n    "},"createCounterpartyIndividual":{"summary":"Create counterparty individual","value":"\n{\n  \"companies\": [],\n  \"officers\": [\n    {\n      \"referenceId\": \"john-doe\",\n      \"firstName\": \"John\",\n      \"lastName\": \"Doe\",\n      \"type\": \"counterparty\"\n    }\n  ]\n}\n    "},"deleteCounterpartyIndividual":{"summary":"Delete counterparty individual","value":"\n{\n  \"companies\": [],\n  \"officers\": [\n    {\n      \"referenceId\": \"john-doe\",\n      \"firstName\": \"John\",\n      \"lastName\": \"Doe\",\n      \"type\": \"counterparty\",\n      \"delete\": true\n    }\n  ]\n}\n    "},"createOfficerRelation":{"summary":"Create an officer and relation in a company","value":"\n{\n  \"companies\": [\n    {\n      \"referenceId\": \"acme-inc\",\n      \"name\": \"Acme Inc\",\n      \"registrationNumber\": \"acme-inc\",\n      \"incorporationCountryCode\": \"DK\",\n      \"relatedOfficers\": [\n        {\n          \"referenceId\": \"john-doe\",\n          \"roles\": [\n            {\n              \"name\": \"board of directors\",\n              \"title\": \"Board Member\",\n              \"startAt\": \"2020-01-10\"\n            },\n            {\n              \"name\": \"executive management\",\n              \"title\": \"CEO\"\n            }\n          ],\n          \"ownership\": 30,\n          \"voting\": 30\n        }\n      ]\n    }\n  ],\n  \"officers\": [\n    {\n      \"referenceId\": \"john-doe\",\n      \"firstName\": \"John\",\n      \"lastName\": \"Doe\",\n      \"isPep\": false\n    }\n  ]\n}\n    "},"createOfficerRelationIncremental":{"summary":"Create an officer relation with multiple roles for a previously created officer and a company","value":"\n{\n  \"companies\": [\n    {\n      \"referenceId\": \"acme-inc\",\n      \"relatedOfficers\": [\n        {\n          \"referenceId\": \"john-doe\",\n          \"roles\": [\n            {\n              \"name\": \"board of directors\",\n              \"title\": \"Board Member\"\n            },\n            {\n              \"name\": \"executive management\",\n              \"title\": \"CEO\"\n            }\n          ],\n          \"ownership\": 30,\n          \"voting\": 30\n        }\n      ]\n    }\n  ]\n}\n    "},"createMultipleOfficerRelations":{"summary":"Create multiple officers and their relations in a company","value":"\n{\n  \"companies\": [\n    {\n      \"referenceId\": \"acme-inc\",\n      \"name\": \"Acme Inc\",\n      \"registrationNumber\": \"acme-inc\",\n      \"incorporationCountryCode\": \"DK\",\n      \"relatedOfficers\": [\n        {\n          \"referenceId\": \"john-doe\",\n          \"roles\": [\n            {\n              \"name\": \"board of directors\",\n              \"title\": \"Board Member\"\n            },\n            {\n              \"name\": \"executive management\",\n              \"title\": \"CEO\"\n            }\n          ],\n          \"ownership\": 15,\n          \"voting\": 15\n        },\n        {\n          \"referenceId\": \"jane-doe\",\n          \"roles\": [\n            {\n              \"name\": \"board of directors\",\n              \"title\": \"Chairman\"\n            },\n            {\n              \"name\": \"executive management\",\n              \"title\": \"COO\"\n            }\n          ],\n          \"ownership\": 15,\n          \"voting\":15\n        }\n      ]\n    }\n  ],\n  \"officers\": [\n    {\n      \"referenceId\": \"john-doe\",\n      \"firstName\": \"John\",\n      \"lastName\": \"Doe\",\n      \"isPep\": false\n    },\n    {\n      \"referenceId\": \"jane-doe\",\n      \"firstName\": \"Jane\",\n      \"lastName\": \"Doe\",\n      \"isPep\": false\n    }\n  ]\n}\n    "},"createCaseWithCompany":{"summary":"Create a company and link it to a case","description":"Creates or updates a company with a primary address and contact persons, and associates that company with a case in the same request. Use the company `referenceId` under the case `companies` list to establish the link.","value":"\n{\n  \"companies\": [\n    {\n      \"referenceId\": \"acme-inc\",\n      \"name\": \"Acme Inc\",\n      \"registrationNumber\": \"acme-inc\",\n      \"incorporationCountryCode\": \"DK\",\n      \"addresses\": [\n        {\n          \"type\": \"primary\",\n          \"streetAddress\": \"Elm street\",\n          \"zipCode\": \"2300\",\n          \"city\": \"Copenhagen\",\n          \"countryCode\": \"DK\"\n        }\n      ],\n      \"contactPersons\": [\n        {\n          \"firstName\": \"Jane\",\n          \"lastName\": \"Doe\",\n          \"email\": \"jane.doe@acme.example\"\n        }\n      ]\n    }\n  ],\n  \"cases\": [\n    {\n      \"referenceId\": \"cdd-acme-001\",\n      \"title\": \"Client onboarding - Acme Inc\",\n      \"status\": \"open\",\n      \"type\": \"responder\",\n      \"companies\": [\n        {\n          \"referenceId\": \"acme-inc\"\n        }\n      ]\n    }\n  ]\n}\n    "}}}}},"responses":{"200":{"description":"OK - when all entities are updated"},"201":{"description":"Created - when all entities are created"},"207":{"description":"Multi-Status - when there is a mix of creations, updates, unmodified entities, failures, or warnings"},"400":{"description":"Bad Request - when there are only warnings or failures when syncing the data"}},"security":[{"bearer":[]}],"summary":"Synchronise a list of companies to match the provided state","tags":["Sync"]}},"/api/v1/access-logs":{"get":{"description":"Returns the UTC days that have an access log file, newest first. A day without any requests has no file, so it is not listed.","operationId":"listAccessLogs","parameters":[{"name":"page","required":false,"in":"query","description":"The page to return. The first page is 0.","schema":{"minimum":0,"default":0,"type":"integer"}},{"name":"limit","required":false,"in":"query","description":"Days per page","schema":{"minimum":1,"maximum":100,"default":15,"type":"integer"}},{"name":"from","required":false,"in":"query","description":"Only days on or after this date, as `YYYY-MM-DD`","schema":{"format":"date","example":"2026-09-01","type":"string"}},{"name":"to","required":false,"in":"query","description":"Only days before this date, as `YYYY-MM-DD`. `from=2026-09-01&to=2026-10-01` lists the days in September.","schema":{"format":"date","example":"2026-10-01","type":"string"}}],"responses":{"200":{"description":"A page of days","headers":{"X-Request-Id":{"description":"The ID of the request. Error bodies repeat it as `requestId`. Quote it when you contact support.","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AccessLogList"}}}},"400":{"description":"`validation_failed`: a parameter is invalid. `errors` names each one.","headers":{"X-Request-Id":{"description":"The ID of the request. Error bodies repeat it as `requestId`. Quote it when you contact support.","schema":{"type":"string"}}},"content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"},"example":{"type":"https://api.avallone.io/problems/validation_failed","title":"Validation failed","status":400,"detail":"1 query parameter is invalid.","code":"validation_failed","requestId":"0b8f7c2e-5d1a-4f0e-9a43-6c2d1e7b9f10","errors":[{"parameter":"limit","code":"out_of_range","detail":"limit must not be greater than 100"}]}}}},"401":{"description":"`unauthenticated`: the token is missing, malformed, expired or revoked.","headers":{"X-Request-Id":{"description":"The ID of the request. Error bodies repeat it as `requestId`. Quote it when you contact support.","schema":{"type":"string"}},"WWW-Authenticate":{"description":"Always `Bearer`","schema":{"type":"string","example":"Bearer"}}},"content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"},"example":{"type":"https://api.avallone.io/problems/unauthenticated","title":"Unauthenticated","status":401,"detail":"The token is missing, malformed, expired or revoked.","code":"unauthenticated","requestId":"0b8f7c2e-5d1a-4f0e-9a43-6c2d1e7b9f10","errors":[]}}}},"403":{"description":"`permission_denied`: the token doesn't have `LIST_ACCESS_LOGS`, or access logs aren't turned on for the tenant.","headers":{"X-Request-Id":{"description":"The ID of the request. Error bodies repeat it as `requestId`. Quote it when you contact support.","schema":{"type":"string"}}},"content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"},"example":{"type":"https://api.avallone.io/problems/permission_denied","title":"Permission denied","status":403,"detail":"The token doesn't have the permission this needs.","code":"permission_denied","requestId":"0b8f7c2e-5d1a-4f0e-9a43-6c2d1e7b9f10","errors":[]}}}},"405":{"description":"`method_not_allowed`: the endpoint doesn't support the method. `Allow` lists the methods it supports.","headers":{"X-Request-Id":{"description":"The ID of the request. Error bodies repeat it as `requestId`. Quote it when you contact support.","schema":{"type":"string"}},"Allow":{"description":"The methods the endpoint supports","schema":{"type":"string","example":"GET, HEAD"}}},"content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"},"example":{"type":"https://api.avallone.io/problems/method_not_allowed","title":"Method not allowed","status":405,"detail":"POST isn't supported here. Use GET or HEAD.","code":"method_not_allowed","requestId":"0b8f7c2e-5d1a-4f0e-9a43-6c2d1e7b9f10","errors":[]}}}},"406":{"description":"`not_acceptable`: the endpoint can't return a type the `Accept` header allows.","headers":{"X-Request-Id":{"description":"The ID of the request. Error bodies repeat it as `requestId`. Quote it when you contact support.","schema":{"type":"string"}}},"content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"},"example":{"type":"https://api.avallone.io/problems/not_acceptable","title":"Not acceptable","status":406,"detail":"The Accept header must allow application/json.","code":"not_acceptable","requestId":"0b8f7c2e-5d1a-4f0e-9a43-6c2d1e7b9f10","errors":[]}}}},"500":{"description":"`internal`: something failed on our side.","headers":{"X-Request-Id":{"description":"The ID of the request. Error bodies repeat it as `requestId`. Quote it when you contact support.","schema":{"type":"string"}}},"content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"},"example":{"type":"https://api.avallone.io/problems/internal","title":"Internal error","status":500,"detail":"Something failed on our side.","code":"internal","requestId":"0b8f7c2e-5d1a-4f0e-9a43-6c2d1e7b9f10","errors":[]}}}}},"security":[{"bearer":[]}],"summary":"List the days that have access logs","tags":["Access logs"]}},"/api/v1/access-logs/{date}":{"get":{"description":"Returns one day and the size of its file. Use it to check whether a day has a file before you download it.","operationId":"getAccessLog","parameters":[{"name":"date","required":true,"in":"path","description":"The UTC day, as `YYYY-MM-DD`","schema":{"format":"date","example":"2026-09-25","type":"string"}}],"responses":{"200":{"description":"The day","headers":{"X-Request-Id":{"description":"The ID of the request. Error bodies repeat it as `requestId`. Quote it when you contact support.","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AccessLog"}}}},"400":{"description":"`validation_failed`: a query parameter is invalid, or `date` isn't `YYYY-MM-DD`, isn't a real day, or is in the future.","headers":{"X-Request-Id":{"description":"The ID of the request. Error bodies repeat it as `requestId`. Quote it when you contact support.","schema":{"type":"string"}}},"content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"},"example":{"type":"https://api.avallone.io/problems/validation_failed","title":"Validation failed","status":400,"detail":"1 query parameter is invalid.","code":"validation_failed","requestId":"0b8f7c2e-5d1a-4f0e-9a43-6c2d1e7b9f10","errors":[{"parameter":"date","code":"out_of_range","detail":"date must not be in the future"}]}}}},"401":{"description":"`unauthenticated`: the token is missing, malformed, expired or revoked.","headers":{"X-Request-Id":{"description":"The ID of the request. Error bodies repeat it as `requestId`. Quote it when you contact support.","schema":{"type":"string"}},"WWW-Authenticate":{"description":"Always `Bearer`","schema":{"type":"string","example":"Bearer"}}},"content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"},"example":{"type":"https://api.avallone.io/problems/unauthenticated","title":"Unauthenticated","status":401,"detail":"The token is missing, malformed, expired or revoked.","code":"unauthenticated","requestId":"0b8f7c2e-5d1a-4f0e-9a43-6c2d1e7b9f10","errors":[]}}}},"403":{"description":"`permission_denied`: the token doesn't have `LIST_ACCESS_LOGS`, or access logs aren't turned on for the tenant.","headers":{"X-Request-Id":{"description":"The ID of the request. Error bodies repeat it as `requestId`. Quote it when you contact support.","schema":{"type":"string"}}},"content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"},"example":{"type":"https://api.avallone.io/problems/permission_denied","title":"Permission denied","status":403,"detail":"The token doesn't have the permission this needs.","code":"permission_denied","requestId":"0b8f7c2e-5d1a-4f0e-9a43-6c2d1e7b9f10","errors":[]}}}},"404":{"description":"`not_found`: there is no file for that day. Nobody used Avallone that day, or the day has not been exported yet.","headers":{"X-Request-Id":{"description":"The ID of the request. Error bodies repeat it as `requestId`. Quote it when you contact support.","schema":{"type":"string"}}},"content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"},"example":{"type":"https://api.avallone.io/problems/not_found","title":"Not found","status":404,"detail":"No access log file for 2026-09-25.","code":"not_found","requestId":"0b8f7c2e-5d1a-4f0e-9a43-6c2d1e7b9f10","errors":[]}}}},"405":{"description":"`method_not_allowed`: the endpoint doesn't support the method. `Allow` lists the methods it supports.","headers":{"X-Request-Id":{"description":"The ID of the request. Error bodies repeat it as `requestId`. Quote it when you contact support.","schema":{"type":"string"}},"Allow":{"description":"The methods the endpoint supports","schema":{"type":"string","example":"GET, HEAD"}}},"content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"},"example":{"type":"https://api.avallone.io/problems/method_not_allowed","title":"Method not allowed","status":405,"detail":"POST isn't supported here. Use GET or HEAD.","code":"method_not_allowed","requestId":"0b8f7c2e-5d1a-4f0e-9a43-6c2d1e7b9f10","errors":[]}}}},"406":{"description":"`not_acceptable`: the endpoint can't return a type the `Accept` header allows.","headers":{"X-Request-Id":{"description":"The ID of the request. Error bodies repeat it as `requestId`. Quote it when you contact support.","schema":{"type":"string"}}},"content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"},"example":{"type":"https://api.avallone.io/problems/not_acceptable","title":"Not acceptable","status":406,"detail":"The Accept header must allow application/json.","code":"not_acceptable","requestId":"0b8f7c2e-5d1a-4f0e-9a43-6c2d1e7b9f10","errors":[]}}}},"500":{"description":"`internal`: something failed on our side.","headers":{"X-Request-Id":{"description":"The ID of the request. Error bodies repeat it as `requestId`. Quote it when you contact support.","schema":{"type":"string"}}},"content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"},"example":{"type":"https://api.avallone.io/problems/internal","title":"Internal error","status":500,"detail":"Something failed on our side.","code":"internal","requestId":"0b8f7c2e-5d1a-4f0e-9a43-6c2d1e7b9f10","errors":[]}}}}},"security":[{"bearer":[]}],"summary":"Get one day of access logs","tags":["Access logs"]}},"/api/v1/access-logs/{date}/content":{"get":{"description":"Returns one UTC day of the tenant's HTTP access logs, as the gzipped JSON Lines file it is stored as. The response has no `Content-Encoding`, so unzip the file yourself. Every download is recorded in the activity log.","operationId":"getAccessLogContent","parameters":[{"name":"date","required":true,"in":"path","description":"The UTC day, as `YYYY-MM-DD`","schema":{"format":"date","example":"2026-09-25","type":"string"}}],"responses":{"200":{"description":"The gzipped JSON Lines file","headers":{"X-Request-Id":{"description":"The ID of the request. Error bodies repeat it as `requestId`. Quote it when you contact support.","schema":{"type":"string"}},"Content-Disposition":{"description":"The file name, such as `access-logs-2026-09-25.jsonl.gz`","schema":{"type":"string","example":"attachment; filename=\"access-logs-2026-09-25.jsonl.gz\""}},"Content-Length":{"description":"The size of the file in bytes","schema":{"type":"integer"}}},"content":{"application/gzip":{"schema":{"type":"string","format":"binary"}}}},"400":{"description":"`validation_failed`: a query parameter is invalid, or `date` isn't `YYYY-MM-DD`, isn't a real day, or is in the future.","headers":{"X-Request-Id":{"description":"The ID of the request. Error bodies repeat it as `requestId`. Quote it when you contact support.","schema":{"type":"string"}}},"content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"},"example":{"type":"https://api.avallone.io/problems/validation_failed","title":"Validation failed","status":400,"detail":"1 query parameter is invalid.","code":"validation_failed","requestId":"0b8f7c2e-5d1a-4f0e-9a43-6c2d1e7b9f10","errors":[{"parameter":"date","code":"out_of_range","detail":"date must not be in the future"}]}}}},"401":{"description":"`unauthenticated`: the token is missing, malformed, expired or revoked.","headers":{"X-Request-Id":{"description":"The ID of the request. Error bodies repeat it as `requestId`. Quote it when you contact support.","schema":{"type":"string"}},"WWW-Authenticate":{"description":"Always `Bearer`","schema":{"type":"string","example":"Bearer"}}},"content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"},"example":{"type":"https://api.avallone.io/problems/unauthenticated","title":"Unauthenticated","status":401,"detail":"The token is missing, malformed, expired or revoked.","code":"unauthenticated","requestId":"0b8f7c2e-5d1a-4f0e-9a43-6c2d1e7b9f10","errors":[]}}}},"403":{"description":"`permission_denied`: the token doesn't have `LIST_ACCESS_LOGS`, or access logs aren't turned on for the tenant.","headers":{"X-Request-Id":{"description":"The ID of the request. Error bodies repeat it as `requestId`. Quote it when you contact support.","schema":{"type":"string"}}},"content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"},"example":{"type":"https://api.avallone.io/problems/permission_denied","title":"Permission denied","status":403,"detail":"The token doesn't have the permission this needs.","code":"permission_denied","requestId":"0b8f7c2e-5d1a-4f0e-9a43-6c2d1e7b9f10","errors":[]}}}},"404":{"description":"`not_found`: there is no file for that day. Nobody used Avallone that day, or the day has not been exported yet.","headers":{"X-Request-Id":{"description":"The ID of the request. Error bodies repeat it as `requestId`. Quote it when you contact support.","schema":{"type":"string"}}},"content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"},"example":{"type":"https://api.avallone.io/problems/not_found","title":"Not found","status":404,"detail":"No access log file for 2026-09-25.","code":"not_found","requestId":"0b8f7c2e-5d1a-4f0e-9a43-6c2d1e7b9f10","errors":[]}}}},"405":{"description":"`method_not_allowed`: the endpoint doesn't support the method. `Allow` lists the methods it supports.","headers":{"X-Request-Id":{"description":"The ID of the request. Error bodies repeat it as `requestId`. Quote it when you contact support.","schema":{"type":"string"}},"Allow":{"description":"The methods the endpoint supports","schema":{"type":"string","example":"GET, HEAD"}}},"content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"},"example":{"type":"https://api.avallone.io/problems/method_not_allowed","title":"Method not allowed","status":405,"detail":"POST isn't supported here. Use GET or HEAD.","code":"method_not_allowed","requestId":"0b8f7c2e-5d1a-4f0e-9a43-6c2d1e7b9f10","errors":[]}}}},"406":{"description":"`not_acceptable`: the endpoint can't return a type the `Accept` header allows.","headers":{"X-Request-Id":{"description":"The ID of the request. Error bodies repeat it as `requestId`. Quote it when you contact support.","schema":{"type":"string"}}},"content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"},"example":{"type":"https://api.avallone.io/problems/not_acceptable","title":"Not acceptable","status":406,"detail":"The Accept header must allow application/gzip.","code":"not_acceptable","requestId":"0b8f7c2e-5d1a-4f0e-9a43-6c2d1e7b9f10","errors":[]}}}},"500":{"description":"`internal`: something failed on our side.","headers":{"X-Request-Id":{"description":"The ID of the request. Error bodies repeat it as `requestId`. Quote it when you contact support.","schema":{"type":"string"}}},"content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"},"example":{"type":"https://api.avallone.io/problems/internal","title":"Internal error","status":500,"detail":"Something failed on our side.","code":"internal","requestId":"0b8f7c2e-5d1a-4f0e-9a43-6c2d1e7b9f10","errors":[]}}}}},"security":[{"bearer":[]}],"summary":"Download one day of access logs","tags":["Access logs"]}},"/api/v1/activities":{"get":{"description":"Returns the activity log, newest first. Entries recorded at the same instant are ordered by `id`. Every filter is optional; without any, you page through the whole log of your tenant.","operationId":"listActivities","parameters":[{"name":"page","required":false,"in":"query","description":"The page to return. The first page is 0.","schema":{"minimum":0,"default":0,"type":"integer"}},{"name":"limit","required":false,"in":"query","description":"Entries per page","schema":{"minimum":1,"maximum":100,"default":15,"type":"integer"}},{"name":"types","required":false,"in":"query","description":"Only return activities of these types","schema":{"type":"array","items":{"$ref":"#/components/schemas/ActivityType"}}},{"name":"resourceType","required":false,"in":"query","description":"Only return activities recorded against this kind of record","schema":{"example":"Company","type":"string"}},{"name":"resourceId","required":false,"in":"query","description":"Only return activities recorded against this record","schema":{"format":"uuid","example":"5d6e7f80-1a2b-4c3d-9e8f-7a6b5c4d3e2f","type":"string"}},{"name":"userId","required":false,"in":"query","description":"Only return activities performed by this user","schema":{"format":"uuid","example":"a1b2c3d4-e5f6-4a7b-8c9d-0e1f2a3b4c5d","type":"string"}},{"name":"from","required":false,"in":"query","description":"Only entries created at or after this point in time. An RFC 3339 timestamp, such as `2026-03-01T09:00:00Z`, or a `YYYY-MM-DD` date, which means midnight UTC at the start of that day.","schema":{"example":"2026-03-01","type":"string"}},{"name":"to","required":false,"in":"query","description":"Only entries created before this point in time. Takes the same forms as `from`. `from=2026-03-01&to=2026-04-01` covers all of March.","schema":{"example":"2026-04-01","type":"string"}}],"responses":{"200":{"description":"A page of activity log entries","headers":{"X-Request-Id":{"description":"The ID of the request. Error bodies repeat it as `requestId`. Quote it when you contact support.","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ActivityList"}}}},"400":{"description":"`validation_failed`: a parameter is invalid. `errors` names each one.","headers":{"X-Request-Id":{"description":"The ID of the request. Error bodies repeat it as `requestId`. Quote it when you contact support.","schema":{"type":"string"}}},"content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"},"example":{"type":"https://api.avallone.io/problems/validation_failed","title":"Validation failed","status":400,"detail":"1 query parameter is invalid.","code":"validation_failed","requestId":"0b8f7c2e-5d1a-4f0e-9a43-6c2d1e7b9f10","errors":[{"parameter":"limit","code":"out_of_range","detail":"limit must not be greater than 100"}]}}}},"401":{"description":"`unauthenticated`: the token is missing, malformed, expired or revoked.","headers":{"X-Request-Id":{"description":"The ID of the request. Error bodies repeat it as `requestId`. Quote it when you contact support.","schema":{"type":"string"}},"WWW-Authenticate":{"description":"Always `Bearer`","schema":{"type":"string","example":"Bearer"}}},"content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"},"example":{"type":"https://api.avallone.io/problems/unauthenticated","title":"Unauthenticated","status":401,"detail":"The token is missing, malformed, expired or revoked.","code":"unauthenticated","requestId":"0b8f7c2e-5d1a-4f0e-9a43-6c2d1e7b9f10","errors":[]}}}},"403":{"description":"`permission_denied`: the token doesn't have `LIST_ACTIVITIES`.","headers":{"X-Request-Id":{"description":"The ID of the request. Error bodies repeat it as `requestId`. Quote it when you contact support.","schema":{"type":"string"}}},"content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"},"example":{"type":"https://api.avallone.io/problems/permission_denied","title":"Permission denied","status":403,"detail":"The token doesn't have the permission this needs.","code":"permission_denied","requestId":"0b8f7c2e-5d1a-4f0e-9a43-6c2d1e7b9f10","errors":[]}}}},"405":{"description":"`method_not_allowed`: the endpoint doesn't support the method. `Allow` lists the methods it supports.","headers":{"X-Request-Id":{"description":"The ID of the request. Error bodies repeat it as `requestId`. Quote it when you contact support.","schema":{"type":"string"}},"Allow":{"description":"The methods the endpoint supports","schema":{"type":"string","example":"GET, HEAD"}}},"content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"},"example":{"type":"https://api.avallone.io/problems/method_not_allowed","title":"Method not allowed","status":405,"detail":"POST isn't supported here. Use GET or HEAD.","code":"method_not_allowed","requestId":"0b8f7c2e-5d1a-4f0e-9a43-6c2d1e7b9f10","errors":[]}}}},"406":{"description":"`not_acceptable`: the endpoint can't return a type the `Accept` header allows.","headers":{"X-Request-Id":{"description":"The ID of the request. Error bodies repeat it as `requestId`. Quote it when you contact support.","schema":{"type":"string"}}},"content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"},"example":{"type":"https://api.avallone.io/problems/not_acceptable","title":"Not acceptable","status":406,"detail":"The Accept header must allow application/json.","code":"not_acceptable","requestId":"0b8f7c2e-5d1a-4f0e-9a43-6c2d1e7b9f10","errors":[]}}}},"500":{"description":"`internal`: something failed on our side.","headers":{"X-Request-Id":{"description":"The ID of the request. Error bodies repeat it as `requestId`. Quote it when you contact support.","schema":{"type":"string"}}},"content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"},"example":{"type":"https://api.avallone.io/problems/internal","title":"Internal error","status":500,"detail":"Something failed on our side.","code":"internal","requestId":"0b8f7c2e-5d1a-4f0e-9a43-6c2d1e7b9f10","errors":[]}}}}},"security":[{"bearer":[]}],"summary":"List activity log entries","tags":["Activities"]}},"/api/v1/activities/resource-types":{"get":{"description":"Returns the kinds of record the log has recorded entries against, in alphabetical order. These are the values the `resourceType` filter on `GET /api/v1/activities` accepts. The list covers every tenant, and a type recorded for the first time can take up to an hour to appear.","operationId":"listActivityResourceTypes","parameters":[],"responses":{"200":{"description":"The resource types, under `results`","headers":{"X-Request-Id":{"description":"The ID of the request. Error bodies repeat it as `requestId`. Quote it when you contact support.","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ActivityResourceTypeList"}}}},"400":{"description":"`validation_failed`: the request has a query parameter. This endpoint takes none.","headers":{"X-Request-Id":{"description":"The ID of the request. Error bodies repeat it as `requestId`. Quote it when you contact support.","schema":{"type":"string"}}},"content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"},"example":{"type":"https://api.avallone.io/problems/validation_failed","title":"Validation failed","status":400,"detail":"1 query parameter is invalid.","code":"validation_failed","requestId":"0b8f7c2e-5d1a-4f0e-9a43-6c2d1e7b9f10","errors":[{"parameter":"page","code":"unknown_field","detail":"property page should not exist"}]}}}},"401":{"description":"`unauthenticated`: the token is missing, malformed, expired or revoked.","headers":{"X-Request-Id":{"description":"The ID of the request. Error bodies repeat it as `requestId`. Quote it when you contact support.","schema":{"type":"string"}},"WWW-Authenticate":{"description":"Always `Bearer`","schema":{"type":"string","example":"Bearer"}}},"content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"},"example":{"type":"https://api.avallone.io/problems/unauthenticated","title":"Unauthenticated","status":401,"detail":"The token is missing, malformed, expired or revoked.","code":"unauthenticated","requestId":"0b8f7c2e-5d1a-4f0e-9a43-6c2d1e7b9f10","errors":[]}}}},"403":{"description":"`permission_denied`: the token doesn't have `LIST_ACTIVITIES`.","headers":{"X-Request-Id":{"description":"The ID of the request. Error bodies repeat it as `requestId`. Quote it when you contact support.","schema":{"type":"string"}}},"content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"},"example":{"type":"https://api.avallone.io/problems/permission_denied","title":"Permission denied","status":403,"detail":"The token doesn't have the permission this needs.","code":"permission_denied","requestId":"0b8f7c2e-5d1a-4f0e-9a43-6c2d1e7b9f10","errors":[]}}}},"405":{"description":"`method_not_allowed`: the endpoint doesn't support the method. `Allow` lists the methods it supports.","headers":{"X-Request-Id":{"description":"The ID of the request. Error bodies repeat it as `requestId`. Quote it when you contact support.","schema":{"type":"string"}},"Allow":{"description":"The methods the endpoint supports","schema":{"type":"string","example":"GET, HEAD"}}},"content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"},"example":{"type":"https://api.avallone.io/problems/method_not_allowed","title":"Method not allowed","status":405,"detail":"POST isn't supported here. Use GET or HEAD.","code":"method_not_allowed","requestId":"0b8f7c2e-5d1a-4f0e-9a43-6c2d1e7b9f10","errors":[]}}}},"406":{"description":"`not_acceptable`: the endpoint can't return a type the `Accept` header allows.","headers":{"X-Request-Id":{"description":"The ID of the request. Error bodies repeat it as `requestId`. Quote it when you contact support.","schema":{"type":"string"}}},"content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"},"example":{"type":"https://api.avallone.io/problems/not_acceptable","title":"Not acceptable","status":406,"detail":"The Accept header must allow application/json.","code":"not_acceptable","requestId":"0b8f7c2e-5d1a-4f0e-9a43-6c2d1e7b9f10","errors":[]}}}},"500":{"description":"`internal`: something failed on our side.","headers":{"X-Request-Id":{"description":"The ID of the request. Error bodies repeat it as `requestId`. Quote it when you contact support.","schema":{"type":"string"}}},"content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"},"example":{"type":"https://api.avallone.io/problems/internal","title":"Internal error","status":500,"detail":"Something failed on our side.","code":"internal","requestId":"0b8f7c2e-5d1a-4f0e-9a43-6c2d1e7b9f10","errors":[]}}}}},"security":[{"bearer":[]}],"summary":"List activity resource types","tags":["Activities"]}},"/api/v1/activities/types":{"get":{"description":"Returns every activity type the log can record, in alphabetical order. These are the values the `types` filter on `GET /api/v1/activities` accepts.","operationId":"listActivityTypes","parameters":[],"responses":{"200":{"description":"The activity types, under `results`","headers":{"X-Request-Id":{"description":"The ID of the request. Error bodies repeat it as `requestId`. Quote it when you contact support.","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ActivityTypeList"}}}},"400":{"description":"`validation_failed`: the request has a query parameter. This endpoint takes none.","headers":{"X-Request-Id":{"description":"The ID of the request. Error bodies repeat it as `requestId`. Quote it when you contact support.","schema":{"type":"string"}}},"content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"},"example":{"type":"https://api.avallone.io/problems/validation_failed","title":"Validation failed","status":400,"detail":"1 query parameter is invalid.","code":"validation_failed","requestId":"0b8f7c2e-5d1a-4f0e-9a43-6c2d1e7b9f10","errors":[{"parameter":"page","code":"unknown_field","detail":"property page should not exist"}]}}}},"401":{"description":"`unauthenticated`: the token is missing, malformed, expired or revoked.","headers":{"X-Request-Id":{"description":"The ID of the request. Error bodies repeat it as `requestId`. Quote it when you contact support.","schema":{"type":"string"}},"WWW-Authenticate":{"description":"Always `Bearer`","schema":{"type":"string","example":"Bearer"}}},"content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"},"example":{"type":"https://api.avallone.io/problems/unauthenticated","title":"Unauthenticated","status":401,"detail":"The token is missing, malformed, expired or revoked.","code":"unauthenticated","requestId":"0b8f7c2e-5d1a-4f0e-9a43-6c2d1e7b9f10","errors":[]}}}},"403":{"description":"`permission_denied`: the token doesn't have `LIST_ACTIVITIES`.","headers":{"X-Request-Id":{"description":"The ID of the request. Error bodies repeat it as `requestId`. Quote it when you contact support.","schema":{"type":"string"}}},"content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"},"example":{"type":"https://api.avallone.io/problems/permission_denied","title":"Permission denied","status":403,"detail":"The token doesn't have the permission this needs.","code":"permission_denied","requestId":"0b8f7c2e-5d1a-4f0e-9a43-6c2d1e7b9f10","errors":[]}}}},"405":{"description":"`method_not_allowed`: the endpoint doesn't support the method. `Allow` lists the methods it supports.","headers":{"X-Request-Id":{"description":"The ID of the request. Error bodies repeat it as `requestId`. Quote it when you contact support.","schema":{"type":"string"}},"Allow":{"description":"The methods the endpoint supports","schema":{"type":"string","example":"GET, HEAD"}}},"content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"},"example":{"type":"https://api.avallone.io/problems/method_not_allowed","title":"Method not allowed","status":405,"detail":"POST isn't supported here. Use GET or HEAD.","code":"method_not_allowed","requestId":"0b8f7c2e-5d1a-4f0e-9a43-6c2d1e7b9f10","errors":[]}}}},"406":{"description":"`not_acceptable`: the endpoint can't return a type the `Accept` header allows.","headers":{"X-Request-Id":{"description":"The ID of the request. Error bodies repeat it as `requestId`. Quote it when you contact support.","schema":{"type":"string"}}},"content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"},"example":{"type":"https://api.avallone.io/problems/not_acceptable","title":"Not acceptable","status":406,"detail":"The Accept header must allow application/json.","code":"not_acceptable","requestId":"0b8f7c2e-5d1a-4f0e-9a43-6c2d1e7b9f10","errors":[]}}}},"500":{"description":"`internal`: something failed on our side.","headers":{"X-Request-Id":{"description":"The ID of the request. Error bodies repeat it as `requestId`. Quote it when you contact support.","schema":{"type":"string"}}},"content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"},"example":{"type":"https://api.avallone.io/problems/internal","title":"Internal error","status":500,"detail":"Something failed on our side.","code":"internal","requestId":"0b8f7c2e-5d1a-4f0e-9a43-6c2d1e7b9f10","errors":[]}}}}},"security":[{"bearer":[]}],"summary":"List activity types","tags":["Activities"]}},"/api/v1/companies/by-ref/{refId}":{"get":{"operationId":"ApiCompaniesController_getCompanyByRefId","parameters":[{"name":"refId","required":true,"in":"path","schema":{"type":"string"}}],"responses":{"200":{"description":"Get a company by referenceId","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CompanyDto"}}}},"204":{"description":"Company not found"}},"security":[{"bearer":[]}],"summary":"Get a company by referenceId","tags":["Companies"]}},"/api/v1/companies/{id}":{"get":{"operationId":"ApiCompaniesController_getCompanyById","parameters":[{"name":"id","required":true,"in":"path","schema":{"type":"string"}}],"responses":{"200":{"description":"Get a company by Id","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CompanyDto"}}}},"204":{"description":"Company not found"}},"security":[{"bearer":[]}],"summary":"Get a company by ID","tags":["Companies"]},"put":{"operationId":"ApiCompaniesController_updateCompany","parameters":[{"name":"id","required":true,"in":"path","schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PutCompanyDto"}}}},"responses":{"200":{"description":"Update an existing company.\n      If a property is not provided, it will be left unchanged.\n      To reset a property, set it to null or an empty array for collections.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CompanyDto"}}}},"204":{"description":"Company not found"},"400":{"description":"Invalid request payload"},"500":{"description":"Internal server error"}},"security":[{"bearer":[]}],"summary":"Update a company by ID","tags":["Companies"]},"delete":{"operationId":"ApiCompaniesController_deleteCompany","parameters":[{"name":"id","required":true,"in":"path","schema":{"type":"string"}}],"responses":{"204":{"description":"Delete an existing company by ID"},"404":{"description":"No company matches the given ID"},"500":{"description":"Internal server error"}},"security":[{"bearer":[]}],"summary":"Delete a company by ID","tags":["Companies"]}},"/api/v1/companies":{"get":{"operationId":"ApiCompaniesController_getCompanies","parameters":[{"name":"search","required":false,"in":"query","description":"Search for name, vatNumber, countryCode or referenceId in the format of encoded URI: {\"key\":\"value\"}","schema":{"type":"string"}},{"name":"page","required":false,"in":"query","description":"Number of the page","schema":{"type":"number"}},{"name":"limit","required":false,"in":"query","description":"Number of companies returned per page","schema":{"type":"number"}}],"responses":{"200":{"description":"Get companies","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CompaniesDto"}}}}},"security":[{"bearer":[]}],"summary":"Get list of companies","tags":["Companies"]},"post":{"operationId":"ApiCompaniesController_createCompany","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PostCompanyDto"}}}},"responses":{"201":{"description":"Company created successfully","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreatedCompanyDto"}}}},"400":{"description":"Invalid request payload"},"409":{"description":"A company with the given referenceId already exists"}},"security":[{"bearer":[]}],"summary":"Create a new company","tags":["Companies"]}},"/api/v1/company":{"put":{"deprecated":true,"operationId":"ApiCompaniesController_upsertCompany","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SyncCompanyDto"},"examples":{"Create or update a company":{"value":{"referenceId":"acme-inc","name":"Acme Inc","registrationNumber":"acme-inc","incorporationCountryCode":"DK"},"description":"Creates a new company if referenceId doesn't exist, otherwise updates the existing company. Only specified fields will be modified."}}}}},"responses":{"200":{"description":"Create or update an existing company (deprecated — use PUT /companies/:id)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CompanyDto"}}}},"400":{"description":"Invalid request payload"},"500":{"description":"Internal server error"}},"security":[{"bearer":[]}],"summary":"Experimental","tags":["Companies"]}},"/api/v1/companies/by-ref/{refId}/documents":{"get":{"description":"Read-only. Mutations require the canonical /companies/:id path.","operationId":"ApiCompanyDocumentsController_readCompanyDocumentsByRef","parameters":[{"name":"refId","required":true,"in":"path","schema":{"type":"string"}}],"responses":{"200":{"description":"Company documents","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/CompanyDocumentDto"}}}}},"404":{"description":"Company not found"}},"security":[{"bearer":[]}],"summary":"Get documents for a company by referenceId","tags":["Company Documents"]}},"/api/v1/companies/by-ref/{refId}/documents/{docId}":{"get":{"description":"Read-only. Mutations require the canonical /companies/:id path.","operationId":"ApiCompanyDocumentsController_readDocumentByRef","parameters":[{"name":"refId","required":true,"in":"path","schema":{"type":"string"}},{"name":"docId","required":true,"in":"path","schema":{"type":"string"}}],"responses":{"200":{"description":"Company document","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CompanyDocumentDto"}}}},"404":{"description":"Not found or document belongs to a different company"}},"security":[{"bearer":[]}],"summary":"Get a company document by referenceId and docId","tags":["Company Documents"]}},"/api/v1/companies/by-ref/{refId}/documents/{docId}/content":{"get":{"description":"Read-only. Mutations require the canonical /companies/:id path.","operationId":"ApiCompanyDocumentsController_readDocumentContentByRef","parameters":[{"name":"refId","required":true,"in":"path","schema":{"type":"string"}},{"name":"docId","required":true,"in":"path","schema":{"type":"string"}},{"name":"attachmentId","required":false,"in":"query","schema":{"type":"string"}}],"responses":{"200":{"description":"Company document binary content"},"404":{"description":"Not found or document belongs to a different company"}},"security":[{"bearer":[]}],"summary":"Get document binary content by referenceId and docId","tags":["Company Documents"]}},"/api/v1/companies/{companyId}/documents":{"get":{"operationId":"ApiCompanyDocumentsController_readCompanyDocuments","parameters":[{"name":"companyId","required":true,"in":"path","schema":{"type":"string"}}],"responses":{"200":{"description":"Company documents","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/CompanyDocumentDto"}}}}}},"security":[{"bearer":[]}],"summary":"Get company documents","tags":["Company Documents"]},"post":{"operationId":"ApiCompanyDocumentsController_createCompanyDocuments","parameters":[{"name":"companyId","required":true,"in":"path","schema":{"type":"string"}}],"requestBody":{"required":true,"description":"Company document","content":{"multipart/form-data":{"schema":{"$ref":"#/components/schemas/UploadCompanyDocumentsDto"}}}},"responses":{"201":{"description":"Company document created","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DocumentCreatedReturnType"}}}}},"security":[{"bearer":[]}],"summary":"Upload documents for a company","tags":["Company Documents"]}},"/api/v1/companies/{companyId}/documents/{docId}":{"get":{"operationId":"ApiCompanyDocumentsController_readDocument","parameters":[{"name":"companyId","required":true,"in":"path","schema":{"type":"string"}},{"name":"docId","required":true,"in":"path","schema":{"type":"string"}}],"responses":{"200":{"description":"Company document","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CompanyDocumentDto"}}}},"404":{"description":"Not found or document belongs to a different company"}},"security":[{"bearer":[]}],"summary":"Get company document by ID","tags":["Company Documents"]}},"/api/v1/companies/{companyId}/documents/{docId}/content":{"get":{"operationId":"ApiCompanyDocumentsController_readDocumentContent","parameters":[{"name":"companyId","required":true,"in":"path","schema":{"type":"string"}},{"name":"docId","required":true,"in":"path","schema":{"type":"string"}},{"name":"attachmentId","required":false,"in":"query","schema":{"type":"string"}}],"responses":{"200":{"description":"Company document binary content"},"404":{"description":"Not found or document belongs to a different company"}},"security":[{"bearer":[]}],"summary":"Get company document binary content by document ID","tags":["Company Documents"]}},"/api/v1/company/documents":{"post":{"deprecated":true,"operationId":"ApiCompanyDocumentsController_create","parameters":[],"requestBody":{"required":true,"description":"Company document","content":{"multipart/form-data":{"schema":{"$ref":"#/components/schemas/CreateCompanyDocumentsPublicDto"}}}},"responses":{"201":{"description":"Company document created (deprecated — use POST /companies/:id/documents)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DocumentCreatedReturnType"}}}}},"security":[{"bearer":[]}],"summary":"experimental","tags":["Company Documents"]}},"/api/v1/company-document-types":{"get":{"operationId":"ApiCompanyDocumentTypesController_readDocumentTypes","parameters":[],"responses":{"200":{"description":"Get company document types","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/CompanyDocumentTypeDto"}}}}}},"security":[{"bearer":[]}],"summary":"Get company document types","tags":["Company Document Types"]}},"/api/v1/company-documents/{docId}/resolve":{"get":{"description":"Returns the companyId and canonical URL for the document. Does not return document content — callers must follow the canonical URL.","operationId":"ApiDocumentsController_resolve","parameters":[{"name":"docId","required":true,"in":"path","schema":{"type":"string"}}],"responses":{"200":{"description":"Resolved document location","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ResolveDocumentDto"}}}},"404":{"description":"Document not found"}},"security":[{"bearer":[]}],"summary":"Resolve a bare document ID to its owning company","tags":["Company Documents"]}}},"info":{"title":"Avallone API","description":"Avallone’s Integration API is designed for system to system integration. This allows other systems, like HR systems, ERP systems, CRM Systems, and general integration busses to integrate with Avallone.","version":"0.136.0","contact":{}},"tags":[],"servers":[],"components":{"securitySchemes":{"bearer":{"scheme":"bearer","bearerFormat":"JWT","type":"http"}},"schemas":{"Function":{"type":"object","properties":{}},"CompanyAddressDto":{"type":"object","properties":{"streetAddress":{"type":"string"},"zipCode":{"type":"string"},"city":{"type":"string"},"countryCode":{"type":"string"},"entity":{"type":"object"},"isRestricted":{"type":"boolean"},"canUserAccess":{"type":"boolean"}},"required":["streetAddress","zipCode","city","countryCode"]},"ContactPersonDto":{"type":"object","properties":{"firstName":{"type":"string","example":"Sherlock"},"lastName":{"type":"string","example":"Holmes"},"email":{"type":"string","example":"holmes@bakerstreet.com"}},"required":["firstName","lastName","email"]},"AmlStatusUpdatedByDto":{"type":"object","properties":{"firstName":{"type":"string","example":"Jim"},"lastName":{"type":"string","example":"Moriarty"},"email":{"type":"string","example":"jim@bakerstreet.com"}},"required":["firstName","lastName","email"]},"AmlStatusDto":{"type":"object","properties":{"status":{"type":"string","enum":["none","pending","approved","rejected"],"example":"approved"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"$ref":"#/components/schemas/AmlStatusUpdatedByDto"}},"required":["status"]},"AmlApprovalDto":{"type":"object","properties":{"approvedAt":{"format":"date-time","type":"string"},"approvedBy":{"$ref":"#/components/schemas/AmlStatusUpdatedByDto"}},"required":["approvedAt","approvedBy"]},"RiskScoreCreatedByDto":{"type":"object","properties":{"firstName":{"type":"string","nullable":true,"example":"John"},"lastName":{"type":"string","nullable":true,"example":"Doe"},"email":{"type":"string","example":"john@example.com"}},"required":["email"]},"RiskScorePropertiesDto":{"type":"object","properties":{"overallRiskStatus":{"type":"string","example":"Low"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"nullable":true,"allOf":[{"$ref":"#/components/schemas/RiskScoreCreatedByDto"}]}},"required":["overallRiskStatus","createdAt","createdBy"]},"ApiCounterpartyDto":{"type":"object","properties":{"name":{"type":"string","example":"Acme Inc"},"getRegistrationNumber":{"example":"UK-12345","allOf":[{"$ref":"#/components/schemas/Function"}]},"getAddresses":{"type":"array","items":{"$ref":"#/components/schemas/CompanyAddressDto"}},"referenceId":{"type":"string","example":"12345"},"getContactPerson":{"$ref":"#/components/schemas/ContactPersonDto"},"getIncorporationCountryCode":{"$ref":"#/components/schemas/Function"},"getAmlProperties":{"$ref":"#/components/schemas/AmlStatusDto"},"getAmlStatus":{"deprecated":true,"allOf":[{"$ref":"#/components/schemas/AmlApprovalDto"}]},"customFields":{"type":"object"},"getRiskScoreProperties":{"nullable":true,"allOf":[{"$ref":"#/components/schemas/RiskScorePropertiesDto"}]},"riskScoreData":{"type":"object","properties":{"counterpartyId":{"type":"string"},"riskScore":{"type":"object"},"mapping":{"type":"object"}},"required":["counterpartyId","riskScore","mapping"]},"entity":{"type":"object"},"isRestricted":{"type":"boolean"},"canUserAccess":{"type":"boolean"}},"required":["name","getRegistrationNumber","getAddresses","referenceId","getContactPerson","getIncorporationCountryCode","getAmlProperties","getAmlStatus","customFields"]},"MetaData":{"type":"object","properties":{"currentPage":{"type":"number"},"totalPages":{"type":"number"},"limit":{"type":"number"},"nextPageURI":{"type":"string"}},"required":["currentPage","totalPages","limit","nextPageURI"]},"ApiCounterpartiesResponseDto":{"type":"object","properties":{"results":{"type":"array","items":{"$ref":"#/components/schemas/ApiCounterpartyDto"}},"metadata":{"example":{"currentPage":0,"totalPages":5,"limit":15,"nextPageURI":"string"},"allOf":[{"$ref":"#/components/schemas/MetaData"}]},"entity":{"type":"object"},"isRestricted":{"type":"boolean"},"canUserAccess":{"type":"boolean"}},"required":["results","metadata"]},"TimeIntervalEnum":{"type":"string","enum":["minute","hour","day"]},"ApiIndividualCounterpartyDto":{"type":"object","properties":{"referenceId":{"type":"string","nullable":true},"name":{"type":"string"},"firstName":{"type":"string","nullable":true},"lastName":{"type":"string","nullable":true},"email":{"type":"string","nullable":true},"customFields":{"type":"object"},"getAmlProperties":{"$ref":"#/components/schemas/AmlStatusDto"},"getRiskScoreProperties":{"nullable":true,"allOf":[{"$ref":"#/components/schemas/RiskScorePropertiesDto"}]},"riskScoreData":{"type":"object","properties":{"counterpartyId":{"type":"string"},"riskScore":{"type":"object"},"mapping":{"type":"object"}},"required":["counterpartyId","riskScore","mapping"]},"entity":{"type":"object"},"isRestricted":{"type":"boolean"},"canUserAccess":{"type":"boolean"}},"required":["name","customFields","getAmlProperties"]},"ApiIndividualCounterpartiesResponseDto":{"type":"object","properties":{"results":{"type":"array","items":{"$ref":"#/components/schemas/ApiIndividualCounterpartyDto"}},"metadata":{"example":{"currentPage":0,"totalPages":5,"limit":15,"nextPageURI":"string"},"allOf":[{"$ref":"#/components/schemas/MetaData"}]},"entity":{"type":"object"},"isRestricted":{"type":"boolean"},"canUserAccess":{"type":"boolean"}},"required":["results","metadata"]},"ApiOfficerAddressDto":{"type":"object","properties":{"id":{"type":"string","format":"uuid"},"tenantId":{"type":"string","nullable":true,"format":"uuid"},"streetAddress":{"type":"string","nullable":true},"streetAddress2":{"type":"string","nullable":true},"city":{"type":"string","nullable":true},"stateOrProvince":{"type":"string","nullable":true},"zipCode":{"type":"string","nullable":true},"countryCode":{"type":"string","nullable":true},"type":{"type":"string","nullable":true},"isPrimary":{"type":"boolean"}},"required":["id","isPrimary"]},"ApiOfficerContactDto":{"type":"object","properties":{"id":{"type":"string","format":"uuid"},"tenantId":{"type":"string","nullable":true,"format":"uuid"},"type":{"type":"string","nullable":true},"number":{"type":"string","nullable":true},"isBusiness":{"type":"boolean"},"isPrivate":{"type":"boolean"}},"required":["id","isBusiness","isPrivate"]},"ApiOfficerCitizenshipDto":{"type":"object","properties":{"id":{"type":"string","format":"uuid"},"tenantId":{"type":"string","nullable":true,"format":"uuid"},"countryCode":{"type":"string","nullable":true},"givenAtBirth":{"type":"boolean"}},"required":["id","givenAtBirth"]},"ApiOfficerTaxCountryDto":{"type":"object","properties":{"id":{"type":"string","format":"uuid"},"tenantId":{"type":"string","nullable":true,"format":"uuid"},"countryCode":{"type":"string","nullable":true},"tin":{"type":"string","nullable":true},"isPrimary":{"type":"boolean"}},"required":["id","isPrimary"]},"ApiOfficerTaxInformationDto":{"type":"object","properties":{"id":{"type":"string","format":"uuid"},"tenantId":{"type":"string","nullable":true,"format":"uuid"},"hasRecentTaxChanges":{"type":"boolean","nullable":true},"isUSCitizen":{"type":"boolean","nullable":true},"hasBeenUSCitizen":{"type":"boolean","nullable":true},"taxCountries":{"type":"array","items":{"$ref":"#/components/schemas/ApiOfficerTaxCountryDto"}}},"required":["id","taxCountries"]},"ApiOfficerDto":{"type":"object","properties":{"id":{"type":"string","format":"uuid"},"tenantId":{"type":"string","format":"uuid"},"referenceId":{"type":"string","nullable":true},"type":{"type":"string","enum":["admin","officer","manager","counterparty","api","system","contact_person","responsible","counterparty_officer","agent"]},"categories":{"type":"array","items":{"type":"string"}},"name":{"type":"string"},"firstName":{"type":"string","nullable":true},"lastName":{"type":"string","nullable":true},"email":{"type":"string","nullable":true},"isPep":{"type":"boolean","nullable":true},"dateOfBirth":{"format":"date-time","type":"string","nullable":true},"cityOfBirth":{"type":"string","nullable":true},"countryOfBirth":{"type":"string","nullable":true},"addresses":{"type":"array","items":{"$ref":"#/components/schemas/ApiOfficerAddressDto"}},"contactInfo":{"type":"array","items":{"$ref":"#/components/schemas/ApiOfficerContactDto"}},"citizenships":{"type":"array","items":{"$ref":"#/components/schemas/ApiOfficerCitizenshipDto"}},"taxInformation":{"nullable":true,"allOf":[{"$ref":"#/components/schemas/ApiOfficerTaxInformationDto"}]},"customFields":{"type":"object"}},"required":["id","tenantId","type","categories","name","addresses","contactInfo","citizenships","customFields"]},"RelatedCompanyDetailResponseDto":{"type":"object","properties":{"role":{"type":"string","description":"Name of the company role","example":"General Partner"},"reason":{"type":"string","description":"Why the companies are related","example":"Manages the fund"}}},"RelatedCompanyDto":{"type":"object","properties":{"id":{"type":"string","format":"uuid","description":"Internal ID of the relation itself"},"tenantId":{"type":"string","format":"uuid"},"type":{"enum":["parent","subsidiary"],"type":"string","description":"Direction of the relationship relative to the requested company"},"companyReferenceId":{"type":"string","description":"External reference ID of the related company"},"companyId":{"type":"string","format":"uuid","description":"Internal ID of the related company"},"ownership":{"type":"number","description":"Ownership percentage"},"voting":{"type":"number","description":"Voting percentage"},"notes":{"type":"string","description":"Notes"},"reasons":{"description":"(Deprecated) Reasons without a role. Use details instead, which lists them too. This field will be removed on 2027-06-30.","deprecated":true,"type":"array","items":{"type":"string"}},"details":{"description":"Company roles and reasons on the relation. Each entry is a role, a reason, or a role with a reason.","type":"array","items":{"$ref":"#/components/schemas/RelatedCompanyDetailResponseDto"}},"url":{"type":"string","description":"URI of this relation's own item-level resource"}},"required":["id","tenantId","type","companyId","url"]},"RelatedCompanyDetailDto":{"type":"object","properties":{"role":{"type":"string","description":"Name of a company role that already exists in your tenant. Matched without regard to case.","example":"General Partner"},"reason":{"type":"string","description":"Why the companies are related.","example":"Manages the fund"}}},"RelatedCompanyRelationDetailsDto":{"type":"object","properties":{"ownership":{"type":"number","minimum":0,"maximum":100,"description":"Ownership percentage"},"voting":{"type":"number","minimum":0,"maximum":100,"description":"Voting percentage"},"notes":{"type":"string","description":"Notes"}}},"PostRelatedCompanyDto":{"type":"object","properties":{"ownership":{"type":"number","minimum":0,"maximum":100,"description":"Ownership percentage"},"voting":{"type":"number","minimum":0,"maximum":100,"description":"Voting percentage. If not provided, it will be set to the ownership percentage"},"notes":{"type":"string","description":"Notes"},"childCompanyReferenceId":{"type":"string","deprecated":true},"companyId":{"type":"string","description":"Internal ID of the parent company","format":"uuid"},"companyReferenceId":{"type":"string","description":"External reference ID of the parent company"},"type":{"enum":["parent","subsidiary"],"type":"string","description":"Relationship direction. Determines which side of the relation the path company occupies: \"parent\" makes the related company its parent, \"subsidiary\" makes it a subsidiary."},"reasons":{"description":"(Deprecated) Reasons for the relation. Use details instead. This field will be removed on 2027-06-30. When sent together with details, it must list the same reasons as the entries without a role, otherwise the request returns 400.","deprecated":true,"type":"array","items":{"type":"string"}},"details":{"description":"Company roles and reasons on the relation. Each entry is a role, a reason, or a role with a reason. When sent, the list replaces every role and reason on the relation. When left out on PUT, roles are kept. (Deprecated) An object with ownership, voting and notes is also accepted; send those as top-level fields instead.","oneOf":[{"type":"array","items":{"$ref":"#/components/schemas/RelatedCompanyDetailDto"}},{"$ref":"#/components/schemas/RelatedCompanyRelationDetailsDto"}]}},"required":["type"]},"PutRelatedCompanyDto":{"type":"object","properties":{"ownership":{"type":"number","minimum":0,"maximum":100,"description":"Ownership percentage"},"voting":{"type":"number","minimum":0,"maximum":100,"description":"Voting percentage. If not provided, it will be set to the ownership percentage"},"notes":{"type":"string","description":"Notes"},"childCompanyReferenceId":{"type":"string","deprecated":true},"companyId":{"type":"string","description":"Internal ID of the parent company","format":"uuid"},"companyReferenceId":{"type":"string","description":"External reference ID of the parent company"},"type":{"enum":["parent","subsidiary"],"type":"string","description":"Relationship direction. Determines which side of the relation the path company occupies: \"parent\" makes the related company its parent, \"subsidiary\" makes it a subsidiary."},"reasons":{"description":"(Deprecated) Reasons for the relation. Use details instead. This field will be removed on 2027-06-30. When sent together with details, it must list the same reasons as the entries without a role, otherwise the request returns 400.","deprecated":true,"type":"array","items":{"type":"string"}},"details":{"description":"Company roles and reasons on the relation. Each entry is a role, a reason, or a role with a reason. When sent, the list replaces every role and reason on the relation. When left out on PUT, roles are kept. (Deprecated) An object with ownership, voting and notes is also accepted; send those as top-level fields instead.","oneOf":[{"type":"array","items":{"$ref":"#/components/schemas/RelatedCompanyDetailDto"}},{"$ref":"#/components/schemas/RelatedCompanyRelationDetailsDto"}]}},"required":["type"]},"PatchRelatedCompanyDto":{"type":"object","properties":{"ownership":{"type":"number","minimum":0,"maximum":100,"description":"Ownership percentage"},"voting":{"type":"number","minimum":0,"maximum":100,"description":"Voting percentage"},"notes":{"type":"string","description":"Notes"},"reasons":{"description":"(Deprecated) Reasons for the relation. Use details instead. This field will be removed on 2027-06-30. When sent together with details, it must list the same reasons as the entries without a role, otherwise the request returns 400.","deprecated":true,"type":"array","items":{"type":"string"}},"details":{"nullable":true,"description":"Company roles and reasons on the relation. Each entry is a role, a reason, or a role with a reason. When sent, the list replaces every role and reason on the relation; send null or an empty list to clear them. When left out, roles are kept.","type":"array","items":{"$ref":"#/components/schemas/RelatedCompanyDetailDto"}}}},"RelatedOfficerRoleDto":{"type":"object","properties":{"name":{"type":"string"},"title":{"type":"string"},"startAt":{"format":"date-time","type":"string"},"endAt":{"format":"date-time","type":"string"}},"required":["name"]},"RelatedOfficerDto":{"type":"object","properties":{"officerReferenceId":{"type":"string","description":"External reference ID of the related officer"},"officerId":{"type":"string","format":"uuid","description":"Internal ID of the related officer"},"ownership":{"type":"number","description":"Ownership percentage"},"voting":{"type":"number","description":"Voting percentage"},"notes":{"type":"string","description":"Notes"},"roles":{"type":"array","items":{"$ref":"#/components/schemas/RelatedOfficerRoleDto"}}},"required":["officerId","roles"]},"SyncOfficerRoleDto":{"type":"object","properties":{"name":{"type":"string","description":"Officer role name. Case insensitive values are accepted."},"title":{"type":"string","description":"Title"},"startAt":{"format":"date-time","type":"string","description":"Role start date"},"endAt":{"format":"date-time","type":"string","description":"Role end date"}},"required":["name"]},"PostRelatedOfficerDto":{"type":"object","properties":{"ownership":{"type":"number","minimum":0,"maximum":100,"description":"Ownership percentage"},"voting":{"type":"number","minimum":0,"maximum":100,"description":"Voting percentage. If not provided, it will be set to the ownership percentage"},"notes":{"type":"string","description":"Notes"},"roles":{"description":"Officer roles","type":"array","items":{"$ref":"#/components/schemas/SyncOfficerRoleDto"}},"forceUbo":{"type":"boolean","description":"Marks this related officer as a UBO regardless of ownership/voting percentage"},"childCompanyReferenceId":{"type":"string","deprecated":true},"officerId":{"type":"string","description":"Internal ID of the officer","format":"uuid"},"officerReferenceId":{"type":"string","description":"External reference ID of the officer"}},"required":["roles"]},"PutRelatedOfficerDto":{"type":"object","properties":{"ownership":{"type":"number","minimum":0,"maximum":100,"description":"Ownership percentage"},"voting":{"type":"number","minimum":0,"maximum":100,"description":"Voting percentage. If not provided, it will be set to the ownership percentage"},"notes":{"type":"string","description":"Notes"},"roles":{"description":"Officer roles","type":"array","items":{"$ref":"#/components/schemas/SyncOfficerRoleDto"}},"forceUbo":{"type":"boolean","description":"Marks this related officer as a UBO regardless of ownership/voting percentage"},"childCompanyReferenceId":{"type":"string","deprecated":true},"officerId":{"type":"string","description":"Internal ID of the officer","format":"uuid"},"officerReferenceId":{"type":"string","description":"External reference ID of the officer"}},"required":["roles"]},"SyncConfigDto":{"type":"object","properties":{"companyIdFields":{"description":"Id fields used to lookup existing records. Allowed values: referenceId, name, registrationNumber, type.","default":["referenceId"],"type":"array","items":{"type":"string"}},"officerIdFields":{"description":"Id fields used to lookup existing records. Allowed fields are: referenceId, firstName, lastName, type.","default":["referenceId"],"type":"array","items":{"type":"string"}},"caseIdFields":{"description":"Id fields used to lookup existing records. Allowed fields is referenceId","default":["referenceId"],"type":"array","items":{"type":"string"}},"cleanup":{"type":"boolean","description":"EXPERIMENTAL FEATURE: Controls the update semantics i.e. PUT vs PATCH.\n- When set to 'true': Gives PUT semantics - fields are cleared before update\n- When set to 'false' (default): Gives PATCH semantics - only specified fields are updated\n\nWhat it covers when set to true:\n- For each specified company, all previous field values are cleared before update\n- For each specified company, all relations are cleared before new ones are created\n\nWhat it does NOT cover:\n- Top level entities (companies and officers) are not affected i.e. if you pass\nan empty array of companies, the existing companies are not deleted\n\nNot yet implemented:\n- Cleaning up custom fields for each specified company\n- Cleaning up addresses for each specified company\n- Cleaning up custom fields for each specified officer","default":false},"sync":{"description":"Specify which sync operation to activate.","default":["companies","officers","company-relations","officer-relations","cases"],"type":"array","items":{"type":"object"}},"saveReferenceId":{"type":"boolean","description":"Reference Id is saved for companies if the companyIdFields contains 'referenceId'. \nSame applies to officers, i.e. if the 'officerIdFields' contains 'referenceId', then it is stored. \nIn other cases it is not stored by default. \nIf you want to explicitly save the referenceId, then set this to true."}}},"SyncCompanyAddressDto":{"type":"object","properties":{"streetAddress":{"type":"string","description":"Street"},"zipCode":{"type":"string","description":"Zip or Postal code"},"city":{"type":"string","description":"City"},"countryCode":{"type":"string","description":"Country code"}},"required":["streetAddress","countryCode"]},"SyncCompanyAddressV1Dto":{"type":"object","properties":{"primary":{"$ref":"#/components/schemas/SyncCompanyAddressDto"}}},"SyncCompanyAddressV2Dto":{"type":"object","properties":{"type":{"type":"string","enum":["primary","business"]},"streetAddress":{"type":"string","description":"Street"},"zipCode":{"type":"string","description":"Zip or Postal code"},"city":{"type":"string","description":"City"},"countryCode":{"type":"string","description":"Country code"}},"required":["type","streetAddress","countryCode"]},"SyncParentCompanyDto":{"type":"object","properties":{"referenceId":{"type":"string","description":"The parent relation to the company. This ID is the primary ID used in the source of the data"},"delete":{"type":"boolean","description":"Delete action! Set to true to remove this relation","default":false},"ownership":{"type":"number","minimum":0,"maximum":100,"description":"Ownership percentage"},"voting":{"type":"number","minimum":0,"maximum":100,"description":"Voting percentage. If not provided, it will be set to the ownership percentage"},"notes":{"type":"string","description":"Notes"},"reasons":{"description":"Reasons for company relation, if no ownership/voting is provided.","type":"array","items":{"type":"string"}},"childCompanyReferenceId":{"type":"string","deprecated":true}},"required":["referenceId"]},"SyncRelatedCompanyDetailDto":{"type":"object","properties":{"role":{"type":"string","description":"Name of a company role that already exists in your tenant. Matched without regard to case.","example":"General Partner"},"reason":{"type":"string","description":"Why the companies are related.","example":"Manages the fund"},"delete":{"type":"boolean","description":"Set to true to remove this role, or this reason when the entry has no role. Only needed without cleanup: with cleanup, details already replaces the whole list. Removing something that is not there does nothing.","default":false}}},"SyncRelatedCompanyDto":{"type":"object","properties":{"referenceId":{"type":"string","description":"The parent relation to the company. This ID is the primary ID used in the source of the data"},"delete":{"type":"boolean","description":"Delete action! Set to true to remove this relation","default":false},"ownership":{"type":"number","minimum":0,"maximum":100,"description":"Ownership percentage"},"voting":{"type":"number","minimum":0,"maximum":100,"description":"Voting percentage. If not provided, it will be set to the ownership percentage"},"notes":{"type":"string","description":"Notes"},"reasons":{"description":"(Deprecated) Reasons for company relation, if no ownership/voting is provided. Use details instead. This field will be removed on 2027-06-30. When sent together with details, it must list the same reasons as the entries without a role, otherwise the relation fails.","deprecated":true,"type":"array","items":{"type":"string"}},"childCompanyReferenceId":{"type":"string","deprecated":true},"details":{"description":"Company roles and reasons on the relation. Each entry is a role, a reason, or a role with a reason. Without cleanup, the entries are added to what the relation has: a role already there takes the new reason when one is given, and nothing is removed unless the entry has delete: true. With cleanup, the list replaces every role and reason. When details is left out, roles are kept.","type":"array","items":{"$ref":"#/components/schemas/SyncRelatedCompanyDetailDto"}}},"required":["referenceId"]},"SyncSpecialRightDto":{"type":"object","properties":{"specialRightType":{"type":"string","description":"Special right type name"},"description":{"type":"string","description":"Special right description"}},"required":["specialRightType"]},"SyncRelatedOfficerDto":{"type":"object","properties":{"referenceId":{"type":"string","description":"The parent relation to the company. This ID is the primary ID used in the source of the data"},"delete":{"type":"boolean","description":"Delete action! Set to true to remove this relation","default":false},"ownership":{"type":"number","minimum":0,"maximum":100,"description":"Ownership percentage"},"voting":{"type":"number","minimum":0,"maximum":100,"description":"Voting percentage. If not provided, it will be set to the ownership percentage"},"notes":{"type":"string","description":"Notes"},"roles":{"description":"Officer roles","type":"array","items":{"$ref":"#/components/schemas/SyncOfficerRoleDto"}},"specialRights":{"description":"Special rights","type":"array","items":{"$ref":"#/components/schemas/SyncSpecialRightDto"}},"forceUbo":{"type":"boolean","description":"Marks this related officer as a UBO regardless of ownership/voting percentage"},"childCompanyReferenceId":{"type":"string","deprecated":true}},"required":["referenceId","roles"]},"SyncCustomFieldsDto":{"type":"object","properties":{}},"SyncTaxInfoDto":{"type":"object","properties":{"countryCode":{"type":"string","description":"Country code"},"taxNumber":{"type":"string","description":"Tax Number"},"isTin":{"type":"boolean","description":"Is the Tax Number a TIN?"},"delete":{"type":"boolean","description":"Delete action! Set to true to remove this relation","default":false},"companyReferenceId":{"type":"string","deprecated":true}},"required":["countryCode","taxNumber","isTin"]},"SyncCompanyLicenseDto":{"type":"object","properties":{"name":{"type":"string","description":"License name","enum":["gambling-business-license","fundraising-permit","arms-and-weapons-export-license","duals-use-good-export-authorization","entity-has-no-license(s)-or-equivalent","other"]},"delete":{"type":"boolean","description":"Delete action! Set to true to remove this relation","default":false},"companyReferenceId":{"type":"string","deprecated":true}},"required":["name"]},"SyncCompanyContactPersonDto":{"type":"object","properties":{"firstName":{"type":"string"},"lastName":{"type":"string"},"email":{"type":"string","format":"email"},"isPrimary":{"type":"boolean"},"delete":{"type":"boolean","description":"Delete action! Set to true to remove this relation","default":false},"companyReferenceId":{"type":"string"}}},"CounterpartyTypeDto":{"type":"object","properties":{"name":{"type":"string","enum":["Agents","Customers","Customer","Employees","Employee","Investors","Investor","Partners","Suppliers","Supplier","Vendors","Tenants","Other","Buyer","Seller","Joint Venture Partner","Borrower","Target company","Direct Counterparty","Indirect Counterparty","Facility Bank","Co-Shareholder / Joint Venture Partner","Vessel","Contingent Worker","Non-Worker"]},"description":{"type":"string"},"entity":{"type":"object"},"isRestricted":{"type":"boolean"},"canUserAccess":{"type":"boolean"}},"required":["name","description"]},"SyncCounterpartyDto":{"type":"object","properties":{"roles":{"description":"Counterparty roles","type":"array","items":{"$ref":"#/components/schemas/CounterpartyTypeDto"}},"followUpAt":{"type":"string","description":"Follow-up due date for counterparty rows (YYYY-MM-DD)"},"riskValue":{"type":"string","description":"Risk score value label (e.g. Low, Medium, High). Must match a risk value configured for your tenant (case-insensitive)."},"amlStatus":{"type":"string","description":"AML status. Accepted values: none, pending, approved, rejected.","enum":["none","pending","approved","rejected"]}}},"SyncIndustryCodeDto":{"type":"object","properties":{"code":{"type":"string","description":"Industry code"},"name":{"type":"string","description":"Industry name"}},"required":["code","name"]},"SyncCompanyDto":{"type":"object","properties":{"referenceId":{"type":"string","description":"Primary Id of the company coming from the external system\n    i.e. source of the data. This value should be set to a value that is unique\n    and identifiable for the integrating solution"},"registrationNumber":{"type":"string","description":"Registration number"},"vatNumber":{"type":"string","description":"VAT number"},"name":{"type":"string","description":"Company name"},"incorporatedAt":{"format":"date-time","type":"string","description":"Date of incorporation"},"incorporationCity":{"type":"string","description":"City of incorporation"},"incorporationCountryCode":{"type":"string","description":"Country of incorporation"},"taxNumber":{"type":"string","description":"Tax ID number (TIN). Use this in case the TIN is different from the registration number"},"lei":{"type":"string","description":"Legal Entity Identifier (LEI)"},"groupConnection":{"type":"string","description":"Group connection","default":"Group company"},"legalForm":{"type":"string","description":"Legal form. Recommended values are Limited Liability Company', 'Public sector/Government', 'Partnership', 'Co-operative', 'Association', 'Foundation/Trust', 'Other etc. The value 'Fund' is deprecated: it is still accepted and marks the company as a Fund.","enum":["Limited Liability Company","Public sector/Government","Partnership","Co-operative","Association","Foundation/Trust","Other","Fund"]},"legalTypes":{"type":"array","description":"Legal types","items":{"type":"string","enum":["Financial institution","Charitable organization","International organization","Danish housing associations (e.g., Andelsboligforening)"]}},"addresses":{"type":"array","items":{"oneOf":[{"$ref":"#/components/schemas/SyncCompanyAddressV2Dto"},{"$ref":"#/components/schemas/SyncCompanyAddressV1Dto"}]}},"parentCompanies":{"description":"Parents of the company. (Deprecated) Use relatedCompanies instead.","deprecated":true,"type":"array","items":{"$ref":"#/components/schemas/SyncParentCompanyDto"}},"relatedCompanies":{"description":"Related companies of the company","type":"array","items":{"$ref":"#/components/schemas/SyncRelatedCompanyDto"}},"relatedOfficers":{"description":"Officers of the company","type":"array","items":{"$ref":"#/components/schemas/SyncRelatedOfficerDto"}},"customFields":{"description":"Some fields might be required depending on how you have\n    configured the 'Company Model' in the platform","allOf":[{"$ref":"#/components/schemas/SyncCustomFieldsDto"}]},"isSelfOwned":{"type":"boolean","description":"Is the company self owned e.g. foundation, self-governed institution etc.?"},"giin":{"type":"string","description":"Global Intermediary Identification Number (GIIN), applied only for financial institutions"},"isListed":{"type":"boolean","description":"Is the company listed on a stock exchange?"},"stockExchangeName":{"type":"string","description":"Name of the stock exchange where the company is listed"},"stockExchangeCountryCode":{"type":"string","description":"Country of the stock exchange where the company is listed"},"isUnderSupervision":{"type":"boolean","description":"Is the company under supervision?"},"supervisingInstitutionName":{"type":"string","description":"Name of the supervising institution"},"supervisorLicenseNumber":{"type":"string","description":"Supervisor license number"},"hasForeignTax":{"type":"boolean","description":"Does the company pay tax in foreign countries than country of incorporation?"},"foreignTaxInfo":{"description":"Foreign tax information i.e. if tax is paid in a country other than the country of incorporation","type":"array","items":{"$ref":"#/components/schemas/SyncTaxInfoDto"}},"hasLicenses":{"type":"boolean","description":"Does the company possess any kind of licenses?"},"licenses":{"description":"License information","type":"array","items":{"$ref":"#/components/schemas/SyncCompanyLicenseDto"}},"type":{"type":"string","default":"entity","enum":["counterparty","entity","related_company"],"description":"Company type"},"contactPersons":{"description":"Contact person of the company","type":"array","items":{"$ref":"#/components/schemas/SyncCompanyContactPersonDto"}},"counterparty":{"description":"Counterparty related fields","allOf":[{"$ref":"#/components/schemas/SyncCounterpartyDto"}]},"attachments":{"description":"Attachments","default":false,"type":"array","items":{"type":"object"}},"categories":{"description":"Categories - related_party or opposing_party","type":"array","items":{"type":"object"}},"industryCodes":{"description":"Industry codes","type":"array","items":{"$ref":"#/components/schemas/SyncIndustryCodeDto"}},"delete":{"type":"boolean"},"id":{"type":"string"},"entity":{"type":"object"},"isRestricted":{"type":"boolean"},"canUserAccess":{"type":"boolean"}},"required":["referenceId","name"]},"SyncOfficerCitizenshipDto":{"type":"object","properties":{"countryCode":{"type":"string","description":"Country code"},"givenAtBirth":{"type":"boolean","description":"Given at birth"},"socialSecurityNumber":{"type":"string","description":"Social security number"},"delete":{"type":"boolean","description":"Delete action! Set to true to remove this relation","default":false},"officerReferenceId":{"type":"string","deprecated":true}},"required":["countryCode"]},"SyncOfficerContactDto":{"type":"object","properties":{"type":{"type":"string","description":"Contact type","enum":["personal-mobile","personal-landline","business-mobile","business-landline","personal-e-mail","business-e-mail"]},"details":{"type":"string","description":"Contact details e.g. e-mail, phone number, etc"},"delete":{"type":"boolean","description":"Delete action! Set to true to remove this relation","default":false},"officerReferenceId":{"type":"string","deprecated":true}},"required":["type","details"]},"SyncOfficerAddressDto":{"type":"object","properties":{"type":{"type":"string","enum":["primary","business"]},"streetAddress":{"type":"string","description":"Street"},"zipCode":{"type":"string","description":"Zip or Postal code"},"city":{"type":"string","description":"City"},"countryCode":{"type":"string","description":"Country code"},"officerReferenceId":{"type":"string"},"isPrimary":{"type":"boolean"}},"required":["type","streetAddress"]},"SyncOfficerDto":{"type":"object","properties":{"referenceId":{"type":"string","description":"Primary Id of the officer coming from the external system\n    i.e. source of the data"},"firstName":{"type":"string","description":"First name"},"lastName":{"type":"string","description":"Last name"},"email":{"type":"string","format":"email","description":"email"},"isPep":{"type":"boolean","description":"Is the officer a PEP or not?"},"dateOfBirth":{"type":"string","description":"Date of birth"},"cityOfBirth":{"type":"string","description":"City of birth"},"countryOfBirth":{"type":"string","description":"Country of birth"},"citizenships":{"description":"Citizenship information","type":"array","items":{"$ref":"#/components/schemas/SyncOfficerCitizenshipDto"}},"contactInfo":{"description":"Contact information","type":"array","items":{"$ref":"#/components/schemas/SyncOfficerContactDto"}},"customFields":{"description":"Some fields might be required depending on how you have\n    configured the 'User Model' in the platform","allOf":[{"$ref":"#/components/schemas/SyncCustomFieldsDto"}]},"counterparty":{"description":"Counterparty related fields","allOf":[{"$ref":"#/components/schemas/SyncCounterpartyDto"}]},"type":{"type":"string","default":"officer","enum":["officer","counterparty"],"description":"Officer type"},"addresses":{"type":"array","items":{"$ref":"#/components/schemas/SyncOfficerAddressDto"}},"delete":{"type":"boolean","description":"Delete action! Set to true to remove this relation","default":false},"attachments":{"description":"Attachments","default":false,"type":"array","items":{"type":"object"}},"categories":{"description":"Categories - related_party or opposing_party","type":"array","items":{"type":"object"}},"hasRecentTaxChanges":{"type":"boolean","description":"Has the officer recent tax changes"},"isUSCitizen":{"type":"boolean","description":"Is the officer currently a US citizen"},"hasBeenUSCitizen":{"type":"boolean","description":"Has the officer at some point been a US citizen"},"taxCountryCode":{"type":"string","description":"tax country for the officer"},"tinNumber":{"type":"string","description":"tax identification number for the officer"},"id":{"type":"string"},"entity":{"type":"object"},"isRestricted":{"type":"boolean"},"canUserAccess":{"type":"boolean"}},"required":["referenceId"]},"SyncCaseCompanyDto":{"type":"object","properties":{"referenceId":{"type":"string","description":"Company reference ID"},"delete":{"type":"boolean","description":"Flag to indicate if the relationship should be deleted."},"caseReferenceId":{"type":"string","deprecated":true}},"required":["referenceId"]},"SyncCaseOfficerDto":{"type":"object","properties":{"referenceId":{"type":"string","description":"Officer reference ID"},"delete":{"type":"boolean","description":"Flag to indicate if the relationship should be deleted."},"caseReferenceId":{"type":"string","deprecated":true}},"required":["referenceId"]},"SyncCaseDto":{"type":"object","properties":{"referenceId":{"type":"string","description":"Primary Id of the case coming from the external system\n    i.e. source of the data. This value should be set to a value that is unique\n    and identifiable for the integrating solution"},"title":{"type":"string","description":"Title of the case"},"description":{"type":"string","description":"Description of the case"},"dueAt":{"format":"date-time","type":"string","description":"Due date of the case"},"status":{"type":"string","enum":["open","closed"],"description":"Status of the case"},"type":{"type":"string","enum":["collector","responder"],"description":"Case type: collector (counterparty / `Case` request) or responder (`Inbound` request)"},"delete":{"type":"boolean","description":"Flag to indicate if the case should be deleted. Not supported for cases.","default":false},"companies":{"description":"Companies associated with the case","type":"array","items":{"$ref":"#/components/schemas/SyncCaseCompanyDto"}},"officers":{"description":"Officers associated with the case","type":"array","items":{"$ref":"#/components/schemas/SyncCaseOfficerDto"}},"customFields":{"description":"Some fields might be required depending on how you have\n    configured the 'Case Model' in the platform","allOf":[{"$ref":"#/components/schemas/SyncCustomFieldsDto"}]}},"required":["referenceId","title","status","type"]},"SyncPayloadDto":{"type":"object","properties":{"config":{"description":"Configuration","allOf":[{"$ref":"#/components/schemas/SyncConfigDto"}]},"companies":{"description":"Companies","type":"array","items":{"$ref":"#/components/schemas/SyncCompanyDto"}},"officers":{"description":"Officers","type":"array","items":{"$ref":"#/components/schemas/SyncOfficerDto"}},"cases":{"description":"Cases","type":"array","items":{"$ref":"#/components/schemas/SyncCaseDto"}}}},"ProblemError":{"type":"object","properties":{"pointer":{"type":"string","description":"Where the problem is in the request body, as a JSON Pointer (RFC 6901)"},"parameter":{"type":"string","description":"The path or query parameter with the problem","example":"limit"},"code":{"type":"string","description":"What is wrong. We may add codes.","enum":["required","invalid_type","invalid_format","invalid_value","out_of_range","too_long","too_many_items","unknown_field","create_only","not_found"],"example":"out_of_range"},"detail":{"type":"string","description":"What is wrong, written for people","example":"limit must not be greater than 100"}},"required":["code","detail"]},"Problem":{"type":"object","properties":{"type":{"type":"string","description":"A URI that identifies the kind of problem","example":"https://api.avallone.io/problems/validation_failed"},"title":{"type":"string","description":"A short summary of the kind of problem","example":"Validation failed"},"status":{"type":"integer","description":"The HTTP status code","example":400},"detail":{"type":"string","description":"What went wrong in this request, written for people","example":"1 query parameter is invalid."},"code":{"type":"string","description":"A stable, machine-readable code. We may add codes.","example":"validation_failed"},"requestId":{"type":"string","description":"The ID of the request. Quote it when you contact support.","example":"0b8f7c2e-5d1a-4f0e-9a43-6c2d1e7b9f10","nullable":true},"errors":{"description":"One entry per input that has a problem. Empty when the problem is not tied to a specific input.","type":"array","items":{"$ref":"#/components/schemas/ProblemError"}}},"description":"An error response in the Problem Details format (RFC 9457), sent as `application/problem+json`","required":["type","title","status","detail","code","requestId","errors"]},"AccessLog":{"type":"object","properties":{"date":{"type":"string","description":"The UTC day, as `YYYY-MM-DD`. This is the day's identifier.","format":"date","example":"2026-09-25","readOnly":true},"url":{"type":"string","description":"The path of the day","example":"/api/v1/access-logs/2026-09-25","readOnly":true},"contentUrl":{"type":"string","description":"The path that downloads the day's file","example":"/api/v1/access-logs/2026-09-25/content","readOnly":true},"size":{"type":"integer","description":"The size of the file in bytes, compressed","example":1834211,"readOnly":true}},"description":"One UTC day that has an access log file","required":["date","url","contentUrl","size"]},"PageMetadata":{"type":"object","properties":{"currentPage":{"type":"integer","description":"The page you asked for. The first page is 0.","example":0,"readOnly":true},"totalPages":{"type":"integer","description":"How many pages the list has, with your filters","example":5,"readOnly":true},"limit":{"type":"integer","description":"Items per page","example":15,"readOnly":true},"nextPageUrl":{"type":"string","nullable":true,"description":"The path of the next page, with your filters. `null` on the last page.","example":"/api/v1/activities?page=1&limit=15","readOnly":true}},"required":["currentPage","totalPages","limit","nextPageUrl"]},"AccessLogList":{"type":"object","properties":{"results":{"readOnly":true,"type":"array","items":{"$ref":"#/components/schemas/AccessLog"}},"metadata":{"readOnly":true,"allOf":[{"$ref":"#/components/schemas/PageMetadata"}]}},"required":["results","metadata"]},"ActivityType":{"type":"string","enum":["login","switch-tenant","document-uploaded","document-request-add","document-request-delete","document-request-upload","document-request-granted","document-access-revoked","document-request-update","document-requirement-default-add","document-requirement-default-remove","document-download-generate","document-download-delete","document-download-get","package-download-agreement-accepted","document-download-expire","document-archive-generated","document-archive-downloaded","document-deleted","permissions-group-add-user","permissions-group-remove-user","permissions-group-add-feature","permissions-group-remove-feature","permissions-group-created","permissions-group-deleted","eav-add","email-template-edit","manager-added","manager-archived","manager-reinvited","manager-deleted","tenant-added","company-created","company-edited","company-deleted","company-document-created","company-document-edited","company-document-deleted","company-document-cloned","global-document-cloned","global-document-signature-requested","global-document-signature-reminded","global-document-signature-cancelled","global-document-signed","global-document-signature-declined","company-document-request-created","company-document-request-edited","company-document-request-deleted","company-document-request-completed","company-document-downloaded","company-document-signature-requested","company-document-signature-reminded","company-document-signature-cancelled","company-document-signed","company-document-signature-declined","company-contact-person-created","company-contact-person-deleted","company-license-created","company-license-edited","company-license-deleted","company-address-created","company-address-edited","company-address-deleted","company-additional-info-edited","company-foreign-tax-info-created","company-foreign-tax-info-edited","company-foreign-tax-info-deleted","company-relation-created","company-relation-updated","company-relation-deleted","company-structure-exported","company-role-created","company-role-updated","company-role-deleted","officer-created","officer-added","officer-edited","officer-archived","officer-unarchived","officer-deleted","officer-role-added","officer-contact-person-added","officer-contact-person-removed","officer-citizenship-created","officer-citizenship-edited","officer-citizenship-deleted","company-officer-removed","officer-address-created","officer-address-edited","officer-address-deleted","officer-accepted-policy","agreement-accepted","officer-tax-information-edited","officer-tax-country-edited","officer-tax-country-created","officer-tax-country-deleted","officer-email-edited","officer-email-added","officer-email-deleted","officer-government-issued-id-edited","officer-government-issued-id-deleted","officer-government-issued-id-created","officer-contact-edited","officer-contact-deleted","officer-contact-created","officer-document-downloaded","officer-document-cloned","officer-document-signature-requested","officer-document-signature-reminded","officer-document-signature-cancelled","officer-document-signed","officer-document-signature-declined","third-party-created","third-party-edited","third-party-deleted","third-party-view","revoke-package-token","package-link-otp-requested","package-link-access-denied","case-package-created","case-package-created-and-shared","API-view-company","API-view-companies","API-view-officer","API-company-created","API-company-edited","API-token-create","API-token-deactivate","API-user-create","API-user-add-to-api-group","API-company-structure-view","API-company-structure-created","API-company-structure-edited","API-company-structure-deleted","API-access-logs-requested","request-created","request-edited","request-deleted","request-status-changed","request-approval-flow-changed","request-file-created","request-file-downloaded","request-file-deleted","request-file-updated","request-comment-created","request-file-comment-created","request-communication-comment-created","request-template-created","note-created","reminder-company-document-expiring","reminder-officer-document-expiring","notification-questionnaire-ready","reminder-document-due-date-approaching","user-data-request-sent","user-data-request-completed","user-additional-info-edited","counterparty-created","counterparty-deleted","counterparty-updated","counterparty-archived","counterparty-unarchived","counterparty-citizenship-edited","counterparty-citizenship-created","counterparty-citizenship-deleted","counterparty-government-issued-id-edited","counterparty-government-issued-id-created","counterparty-government-issued-id-deleted","counterparty-address-edited","counterparty-address-created","counterparty-address-deleted","counterparty-contact-edited","counterparty-contact-created","counterparty-contact-deleted","counterparty-tax-information-edited","counterparty-tax-information-created","counterparty-tax-country-edited","counterparty-tax-country-created","counterparty-tax-country-deleted","counterparty-risk-score-created","counterparty-risk-score-updated","counterparty-token-created","counterparty-token-extended","counterparty-token-used","counterparty-token-canceled","counterparty-token-expired","counterparty-request-created","counterparty-followup-needed","counterparty-followup-recipients-updated","counterparty-aml-updated","counterparty-aml-removed","counterparty-archived-from-request","counterparty-case-review-updated","counterparty-document-downloaded","counterparty-followup-added-from-risk-score","counterparty-follow-up-at-manually-updated","request-email-reminder-sent","request-recipient-notified","request-auth-link-requested","request-link-copied","questionnaire-request-completed","questionnaire-request-viewed","pdf-questionnaire-digitized","questionnaire-request-answer-updated","outbound-request-activation","outbound-request-closed","outbound-request-reopened","outbound-request-changes-requested","outbound-request-requirement-approved","outbound-request-requirement-approved-with-mitigation","outbound-request-requirement-rejected","outbound-request-requirement-reopened","outbound-request-assignee-approved","outbound-request-assignee-approved-with-mitigation","outbound-request-assignee-rejected","outbound-request-assignee-disregarded","outbound-request-contact-person-added","outbound-request-contact-person-removed","outbound-request-pending-review","outbound-request-request-assignee-blocked","screening-settings-created","screening-settings-updated","screening-case-created","screening-case-rescreened","screening-case-monitoring-changed","screening-case-search-profile-changed","screening-case-status-changed","task-created","task-updated","task-deleted","task-completed","signature-request","manager-edited-questionnaire-answer","approvers-group-created","approvers-group-deleted","approvers-group-renamed","approvers-group-added-user","approvers-group-removed-user","approvers-group-added-attribute","approvers-group-removed_attribute","approvers-group-review-requested","approvers-group-request-reviewed","approvers-group-review-deleted","approvers-group-request-notification-sent","approval-flow-completed-notification-sent","approval-flow-rejected-notification-sent","approval-flow-reset","access-group-created","access-group-deleted","access-group-renamed","access-group-added-user","access-group-removed-user","access-group-added-company","access-group-removed-company","access-group-added-officer","access-group-removed-officer","access-group-added-case","access-group-removed-case","access-group-added-package","access-group-removed-package","attachment-renamed","company-data-exported","import-csv-data","embeddings-created","embeddings-deleted","reminder-deleted","reminder-created","reminder-updated","tenant-feature-updated","tenant-feature-flag-updated","email-alias-created","email-alias-updated","email-alias-removed","scim-user-provisioned","scim-user-updated","scim-user-deactivated","ai-case-agent-email-processed","ai-case-agent-email-failed","chat-agent-access-granted","chat-agent-access-reset"]},"ActivityChange":{"type":"object","properties":{"type":{"type":"string","enum":["change"],"readOnly":true},"field":{"type":"string","nullable":true,"description":"The name of the field that changed. `null` when the entry doesn't say which field.","example":"name","readOnly":true},"before":{"oneOf":[{"type":"string"},{"type":"number"},{"type":"boolean"},{"type":"object"},{"type":"array","items":{}},{"enum":[null]}],"description":"The value before the change. `null` when the field had no value. What it contains depends on the field.","example":"Acme","readOnly":true},"after":{"oneOf":[{"type":"string"},{"type":"number"},{"type":"boolean"},{"type":"object"},{"type":"array","items":{}},{"enum":[null]}],"description":"The value after the change. `null` when the field has no value. What it contains depends on the field.","example":"Acme Inc","readOnly":true}},"description":"One field that changed","required":["type","field","before","after"]},"ActivityMetadata":{"type":"object","properties":{"type":{"type":"string","enum":["metadata"],"readOnly":true},"metadata":{"type":"object","additionalProperties":true,"description":"The details, as key-value pairs. Which keys there are depends on the activity type.","example":{"outcome":"downloaded"},"readOnly":true}},"description":"Other details of the event","required":["type","metadata"]},"ActivityActor":{"type":"object","properties":{"userId":{"type":"string","nullable":true,"format":"uuid","description":"The ID of the user or API user. `null` when Avallone did it, for example in a scheduled job.","example":"a1b2c3d4-e5f6-4a7b-8c9d-0e1f2a3b4c5d","readOnly":true},"name":{"type":"string","nullable":true,"description":"The user's name when the entry was recorded","example":"Jane Doe","readOnly":true},"email":{"type":"string","nullable":true,"description":"The user's email address when the entry was recorded","example":"jane@example.com","readOnly":true},"ipAddress":{"type":"string","nullable":true,"description":"The IP address the request came from. `null` when there is none, for example because a background job recorded the entry.","example":"203.0.113.42","readOnly":true}},"required":["userId","name","email","ipAddress"]},"ActivityResource":{"type":"object","properties":{"type":{"type":"string","description":"The kind of record the entry is about","example":"Company","readOnly":true},"id":{"type":"string","format":"uuid","description":"The ID of the record the entry is about","example":"5d6e7f80-1a2b-4c3d-9e8f-7a6b5c4d3e2f","readOnly":true},"entity":{"type":"object"},"isRestricted":{"type":"boolean"},"canUserAccess":{"type":"boolean"}},"required":["type","id"]},"Activity":{"type":"object","properties":{"id":{"type":"string","format":"uuid","description":"The ID of the entry","example":"3f2a1c40-9c1e-4c7f-9c6b-2b0f7a5d1e88","readOnly":true},"tenantId":{"type":"string","format":"uuid","description":"Your tenant's ID","example":"8b1d0c22-5e4a-4f3b-9a77-1c2d3e4f5a6b","readOnly":true},"type":{"description":"What happened","readOnly":true,"allOf":[{"$ref":"#/components/schemas/ActivityType"}]},"message":{"type":"string","description":"What happened, as a sentence for people to read. Don't parse it: its wording can change.","example":"Jane Doe edited Acme Inc","readOnly":true},"createdAt":{"format":"date-time","type":"string","description":"When it happened","example":"2026-03-14T09:21:44.512Z","readOnly":true},"actor":{"readOnly":true,"allOf":[{"$ref":"#/components/schemas/ActivityActor"}]},"data":{"type":"array","items":{"oneOf":[{"$ref":"#/components/schemas/ActivityChange"},{"$ref":"#/components/schemas/ActivityMetadata"}],"discriminator":{"propertyName":"type","mapping":{"change":"#/components/schemas/ActivityChange","metadata":"#/components/schemas/ActivityMetadata"}}},"description":"What changed, and other details of the event. Empty when the event records no details. We may add kinds of item: skip an item whose `type` you don’t know.","readOnly":true},"resources":{"description":"The records the entry is about","readOnly":true,"type":"array","items":{"$ref":"#/components/schemas/ActivityResource"}},"entity":{"type":"object"},"isRestricted":{"type":"boolean"},"canUserAccess":{"type":"boolean"}},"required":["id","tenantId","type","message","createdAt","actor","data","resources"]},"ActivityList":{"type":"object","properties":{"results":{"readOnly":true,"type":"array","items":{"$ref":"#/components/schemas/Activity"}},"metadata":{"readOnly":true,"allOf":[{"$ref":"#/components/schemas/PageMetadata"}]},"entity":{"type":"object"},"isRestricted":{"type":"boolean"},"canUserAccess":{"type":"boolean"}},"required":["results","metadata"]},"ActivityResourceTypeList":{"type":"object","properties":{"results":{"description":"The kinds of record the log has recorded entries against, in alphabetical order. These are the values the `resourceType` filter accepts.","example":["Company","CompanyDocument","UserTenantRole"],"readOnly":true,"type":"array","items":{"type":"string"}},"entity":{"type":"object"},"isRestricted":{"type":"boolean"},"canUserAccess":{"type":"boolean"}},"required":["results"]},"ActivityTypeList":{"type":"object","properties":{"results":{"description":"Every activity type the log can record, in alphabetical order. These are the values the `types` filter accepts.","example":["company-created","company-deleted","login"],"readOnly":true,"type":"array","items":{"type":"string"}},"entity":{"type":"object"},"isRestricted":{"type":"boolean"},"canUserAccess":{"type":"boolean"}},"required":["results"]},"AddressDto":{"type":"object","properties":{"id":{"type":"string"},"streetAddress":{"type":"string"},"countryCode":{"type":"string"},"zipCode":{"type":"string"},"streetAddress2":{"type":"string"},"city":{"type":"string"},"type":{"type":"string"}},"required":["streetAddress","countryCode"]},"CompanyDto":{"type":"object","properties":{"name":{"type":"string"},"registrationNumber":{"type":"string"},"vatNumber":{"type":"string"},"incorporationCountryCode":{"type":"string","enum":["AD","AE","AF","AG","AI","AL","AM","AN","AO","AQ","AR","AS","AT","AU","AW","AX","AZ","BA","BB","BD","BE","BF","BG","BH","BI","BJ","BL","BM","BN","BO","BQ","BR","BS","BT","BV","BW","BY","BZ","CA","CC","CD","CF","CG","CH","CI","CK","CL","CM","CN","CO","CR","CU","CV","CW","CX","CY","CZ","DE","DJ","DK","DM","DO","DZ","EC","EE","EG","EH","ER","ES","ET","EU","FI","FJ","FK","FM","FO","FR","GA","GB-ENG","GB-NIR","GB-SCT","GB-WLS","GB","GD","GE","GF","GG","GH","GI","GL","GM","GN","GP","GQ","GR","GS","GT","GU","GW","GY","HK","HM","HN","HR","HT","HU","ID","IE","IL","IM","IN","IO","IQ","IR","IS","IT","JE","JM","JO","JP","KE","KG","KH","KI","KM","KN","KP","KR","KW","KY","KZ","LA","LB","LC","LI","LK","LR","LS","LT","LU","LV","LY","MA","MC","MD","ME","MF","MG","MH","MK","ML","MM","MN","MO","MP","MQ","MR","MS","MT","MU","MV","MW","MX","MY","MZ","NA","NC","NE","NF","NG","NI","NL","NO","NP","NR","NU","NZ","OM","PA","PE","PF","PG","PH","PK","PL","PM","PN","PR","PS","PT","PW","PY","QA","RE","RO","RS","RU","RW","SA","SB","SC","SD","SE","SG","SH","SI","SJ","SK","SL","SM","SN","SO","SR","SS","ST","SV","SX","SY","SZ","TC","TD","TF","TG","TH","TJ","TK","TL","TM","TN","TO","TR","TT","TV","TW","TZ","UA","UG","UM","US","UY","UZ","VA","VC","VE","VG","VI","VN","VU","WF","XK","WS","YE","YT","ZA","ZM","ZW"],"description":"Country of incorporation"},"incorporatedAt":{"format":"date-time","type":"string","description":"Date of incorporation"},"incorporationCity":{"type":"string","description":"City of incorporation"},"groupConnection":{"type":"string","description":"Group connection","default":"Group company"},"legalForm":{"type":"string","description":"Legal form. Recommended values are Limited Liability Company', 'Public sector/Government', 'Partnership', 'Co-operative', 'Association', 'Foundation/Trust', 'Other etc. The value 'Fund' is deprecated: it is still accepted and marks the company as a Fund.","enum":["Limited Liability Company","Public sector/Government","Partnership","Co-operative","Association","Foundation/Trust","Other","Fund"]},"legalTypes":{"type":"array","description":"Legal types","items":{"type":"string","enum":["Financial institution","Charitable organization","International organization","Danish housing associations (e.g., Andelsboligforening)"]}},"address":{"$ref":"#/components/schemas/AddressDto"},"addresses":{"type":"array","items":{"$ref":"#/components/schemas/AddressDto"}},"customFields":{"type":"object"},"referenceId":{"type":"string"},"categories":{"description":"Categories - related_party or opposing_party","type":"array","items":{"type":"object"}},"id":{"type":"string"},"tenantId":{"type":"string","format":"uuid"}},"required":["name","id","tenantId"]},"CompaniesDto":{"type":"object","properties":{"metadata":{"$ref":"#/components/schemas/MetaData"},"results":{"type":"object"}},"required":["metadata","results"]},"PostCompanyDto":{"type":"object","properties":{"referenceId":{"type":"string","description":"External reference ID from the integrating system. Optional — if omitted, the response will contain the internal company ID instead."},"registrationNumber":{"type":"string","description":"Registration number"},"vatNumber":{"type":"string","description":"VAT number"},"name":{"type":"string","description":"Company name"},"incorporatedAt":{"format":"date-time","type":"string","description":"Date of incorporation"},"incorporationCity":{"type":"string","description":"City of incorporation"},"incorporationCountryCode":{"type":"string","description":"Country of incorporation"},"taxNumber":{"type":"string","description":"Tax ID number (TIN). Use this in case the TIN is different from the registration number"},"lei":{"type":"string","description":"Legal Entity Identifier (LEI)"},"groupConnection":{"type":"string","description":"Group connection","default":"Group company"},"legalForm":{"type":"string","description":"Legal form. Recommended values are Limited Liability Company', 'Public sector/Government', 'Partnership', 'Co-operative', 'Association', 'Foundation/Trust', 'Other etc. The value 'Fund' is deprecated: it is still accepted and marks the company as a Fund.","enum":["Limited Liability Company","Public sector/Government","Partnership","Co-operative","Association","Foundation/Trust","Other","Fund"]},"legalTypes":{"type":"array","description":"Legal types","items":{"type":"string","enum":["Financial institution","Charitable organization","International organization","Danish housing associations (e.g., Andelsboligforening)"]}},"addresses":{"type":"array","items":{"oneOf":[{"$ref":"#/components/schemas/SyncCompanyAddressV2Dto"},{"$ref":"#/components/schemas/SyncCompanyAddressV1Dto"}]}},"parentCompanies":{"description":"Parents of the company. (Deprecated) Use relatedCompanies instead.","deprecated":true,"type":"array","items":{"$ref":"#/components/schemas/SyncParentCompanyDto"}},"relatedCompanies":{"description":"Related companies of the company","type":"array","items":{"$ref":"#/components/schemas/SyncRelatedCompanyDto"}},"relatedOfficers":{"description":"Officers of the company","type":"array","items":{"$ref":"#/components/schemas/SyncRelatedOfficerDto"}},"customFields":{"description":"Some fields might be required depending on how you have\n    configured the 'Company Model' in the platform","allOf":[{"$ref":"#/components/schemas/SyncCustomFieldsDto"}]},"isSelfOwned":{"type":"boolean","description":"Is the company self owned e.g. foundation, self-governed institution etc.?"},"giin":{"type":"string","description":"Global Intermediary Identification Number (GIIN), applied only for financial institutions"},"isListed":{"type":"boolean","description":"Is the company listed on a stock exchange?"},"stockExchangeName":{"type":"string","description":"Name of the stock exchange where the company is listed"},"stockExchangeCountryCode":{"type":"string","description":"Country of the stock exchange where the company is listed"},"isUnderSupervision":{"type":"boolean","description":"Is the company under supervision?"},"supervisingInstitutionName":{"type":"string","description":"Name of the supervising institution"},"supervisorLicenseNumber":{"type":"string","description":"Supervisor license number"},"hasForeignTax":{"type":"boolean","description":"Does the company pay tax in foreign countries than country of incorporation?"},"foreignTaxInfo":{"description":"Foreign tax information i.e. if tax is paid in a country other than the country of incorporation","type":"array","items":{"$ref":"#/components/schemas/SyncTaxInfoDto"}},"hasLicenses":{"type":"boolean","description":"Does the company possess any kind of licenses?"},"licenses":{"description":"License information","type":"array","items":{"$ref":"#/components/schemas/SyncCompanyLicenseDto"}},"type":{"type":"string","default":"entity","enum":["counterparty","entity","related_company"],"description":"Company type"},"contactPersons":{"description":"Contact person of the company","type":"array","items":{"$ref":"#/components/schemas/SyncCompanyContactPersonDto"}},"counterparty":{"description":"Counterparty related fields","allOf":[{"$ref":"#/components/schemas/SyncCounterpartyDto"}]},"attachments":{"description":"Attachments","default":false,"type":"array","items":{"type":"object"}},"categories":{"description":"Categories - related_party or opposing_party","type":"array","items":{"type":"object"}},"industryCodes":{"description":"Industry codes","type":"array","items":{"$ref":"#/components/schemas/SyncIndustryCodeDto"}},"delete":{"type":"boolean"},"id":{"type":"string"},"entity":{"type":"object"},"isRestricted":{"type":"boolean"},"canUserAccess":{"type":"boolean"}},"required":["name"]},"CreatedCompanyDto":{"type":"object","properties":{"id":{"type":"string","description":"Internal company ID"},"referenceId":{"type":"string","description":"External reference ID — present only when supplied in the request"}},"required":["id"]},"PutCompanyDto":{"type":"object","properties":{"referenceId":{"type":"string","description":"External reference ID (from the integrating system). If provided in the URL\n    (PUT /companies/:id with x-id-field: referenceId), the URL value takes precedence and overrides\n    any value supplied in the request body."},"registrationNumber":{"type":"string","description":"Registration number"},"vatNumber":{"type":"string","description":"VAT number"},"name":{"type":"string","description":"Company name"},"incorporatedAt":{"format":"date-time","type":"string","description":"Date of incorporation"},"incorporationCity":{"type":"string","description":"City of incorporation"},"incorporationCountryCode":{"type":"string","description":"Country of incorporation"},"taxNumber":{"type":"string","description":"Tax ID number (TIN). Use this in case the TIN is different from the registration number"},"lei":{"type":"string","description":"Legal Entity Identifier (LEI)"},"groupConnection":{"type":"string","description":"Group connection","default":"Group company"},"legalForm":{"type":"string","description":"Legal form. Recommended values are Limited Liability Company', 'Public sector/Government', 'Partnership', 'Co-operative', 'Association', 'Foundation/Trust', 'Other etc. The value 'Fund' is deprecated: it is still accepted and marks the company as a Fund.","enum":["Limited Liability Company","Public sector/Government","Partnership","Co-operative","Association","Foundation/Trust","Other","Fund"]},"legalTypes":{"type":"array","description":"Legal types","items":{"type":"string","enum":["Financial institution","Charitable organization","International organization","Danish housing associations (e.g., Andelsboligforening)"]}},"addresses":{"type":"array","items":{"oneOf":[{"$ref":"#/components/schemas/SyncCompanyAddressV2Dto"},{"$ref":"#/components/schemas/SyncCompanyAddressV1Dto"}]}},"parentCompanies":{"description":"Parents of the company. (Deprecated) Use relatedCompanies instead.","deprecated":true,"type":"array","items":{"$ref":"#/components/schemas/SyncParentCompanyDto"}},"relatedCompanies":{"description":"Related companies of the company","type":"array","items":{"$ref":"#/components/schemas/SyncRelatedCompanyDto"}},"relatedOfficers":{"description":"Officers of the company","type":"array","items":{"$ref":"#/components/schemas/SyncRelatedOfficerDto"}},"customFields":{"description":"Some fields might be required depending on how you have\n    configured the 'Company Model' in the platform","allOf":[{"$ref":"#/components/schemas/SyncCustomFieldsDto"}]},"isSelfOwned":{"type":"boolean","description":"Is the company self owned e.g. foundation, self-governed institution etc.?"},"giin":{"type":"string","description":"Global Intermediary Identification Number (GIIN), applied only for financial institutions"},"isListed":{"type":"boolean","description":"Is the company listed on a stock exchange?"},"stockExchangeName":{"type":"string","description":"Name of the stock exchange where the company is listed"},"stockExchangeCountryCode":{"type":"string","description":"Country of the stock exchange where the company is listed"},"isUnderSupervision":{"type":"boolean","description":"Is the company under supervision?"},"supervisingInstitutionName":{"type":"string","description":"Name of the supervising institution"},"supervisorLicenseNumber":{"type":"string","description":"Supervisor license number"},"hasForeignTax":{"type":"boolean","description":"Does the company pay tax in foreign countries than country of incorporation?"},"foreignTaxInfo":{"description":"Foreign tax information i.e. if tax is paid in a country other than the country of incorporation","type":"array","items":{"$ref":"#/components/schemas/SyncTaxInfoDto"}},"hasLicenses":{"type":"boolean","description":"Does the company possess any kind of licenses?"},"licenses":{"description":"License information","type":"array","items":{"$ref":"#/components/schemas/SyncCompanyLicenseDto"}},"type":{"type":"string","default":"entity","enum":["counterparty","entity","related_company"],"description":"Company type"},"contactPersons":{"description":"Contact person of the company","type":"array","items":{"$ref":"#/components/schemas/SyncCompanyContactPersonDto"}},"counterparty":{"description":"Counterparty related fields","allOf":[{"$ref":"#/components/schemas/SyncCounterpartyDto"}]},"attachments":{"description":"Attachments","default":false,"type":"array","items":{"type":"object"}},"categories":{"description":"Categories - related_party or opposing_party","type":"array","items":{"type":"object"}},"industryCodes":{"description":"Industry codes","type":"array","items":{"$ref":"#/components/schemas/SyncIndustryCodeDto"}},"id":{"type":"string","description":"Internal company ID. If provided in the URL (PUT /companies/:id with x-id-field: id),\n    the URL value takes precedence and overrides any value supplied in the request body."},"delete":{"type":"boolean"},"entity":{"type":"object"},"isRestricted":{"type":"boolean"},"canUserAccess":{"type":"boolean"}},"required":["name"]},"CompanyDocumentAttachmentDto":{"type":"object","properties":{"id":{"type":"string","format":"uuid"},"tenantId":{"type":"string","nullable":true,"format":"uuid"},"fileName":{"type":"string"},"mimeType":{"type":"string","nullable":true},"fileSize":{"type":"number","nullable":true},"url":{"type":"string","format":"uri"}},"required":["id","tenantId","fileName","url"]},"CompanyDocumentDto":{"type":"object","properties":{"id":{"type":"string","format":"uuid"},"tenantId":{"type":"string","format":"uuid"},"url":{"type":"string","format":"uri"},"companyId":{"type":"string","format":"uuid"},"companyDocumentTypeId":{"type":"string","format":"uuid"},"companyDocumentTypeName":{"type":"string","nullable":true},"countryCode":{"type":"string","nullable":true},"countryName":{"type":"string","nullable":true},"issueDate":{"format":"date-time","type":"string","nullable":true},"expiringDate":{"format":"date-time","type":"string","nullable":true},"description":{"type":"string","nullable":true},"note":{"type":"string","nullable":true},"referenceId":{"type":"string","nullable":true},"createdAt":{"format":"date-time","type":"string"},"updatedAt":{"format":"date-time","type":"string"},"attachments":{"type":"array","items":{"$ref":"#/components/schemas/CompanyDocumentAttachmentDto"}}},"required":["id","tenantId","url","companyId","companyDocumentTypeId","createdAt","updatedAt","attachments"]},"UploadCompanyDocumentsDto":{"type":"object","properties":{"files":{"type":"string","format":"binary","description":"A file to be uploaded. Must be sent with form-data, and the key must be \"files\". For multiple files, use the same key \"files\" for each file."},"documentMetadatas":{"type":"string","format":"json","description":"A JSON formatted string of an array containing metadata for the file(s) of the request. Must be an array with the same size as the number of files uploaded, and must provide metadata in the exact same order as the file(s)<br ><br />\n      _Valid schema_\n\n    [\n      {\n        \"referenceId\": string - external ID used to reference the document,\n        \"companyDocumentTypeId\": string (UUID),\n        \"countryCode\": string - ISO 3166-1 alpha-2 country code (two letters),\n        \"expiryDate\": Date,\n        \"issueDate\": Date,\n        \"description\": string - optional,\n        \"note\": string - optional\n      }\n    ]\n      "}},"required":["files","documentMetadatas"]},"DocumentCreatedReturnType":{"type":"object","properties":{"results":{"example":"[\"8592a497-e3d5-40df-8eb4-4dc56bf26b1c\", \"688e68ff-ec51-4f85-93b0-483425bf1bcb\"]","type":"array","items":{"type":"string"}}},"required":["results"]},"CreateCompanyDocumentsPublicDto":{"type":"object","properties":{"files":{"type":"string","format":"binary","description":"A file to be uploaded. Must be sent with form-data, and the key must be \"files\". For multiple files, use the same key \"files\" for each file."},"documentMetadatas":{"type":"string","format":"json","description":"A JSON formatted string of an array containing metadata for the file(s) of the request. Must be an array with the same size as the number of files uploaded, and must provide metadata in the exact same order as the file(s)<br ><br />\n      _Valid schema_\n\n    [\n      {\n        \"referenceId\": string - external ID used to reference the document,\n        \"companyDocumentTypeId\": string (UUID),\n        \"countryCode\": string - ISO 3166-1 alpha-2 country code (two letters),\n        \"expiryDate\": Date,\n        \"issueDate\": Date,\n        \"description\": string - optional,\n        \"note\": string - optional\n      }\n    ]\n      "},"companyReferenceId":{"type":"string","format":"uuid","description":"The reference ID for the company the document should be added to"}},"required":["files","documentMetadatas","companyReferenceId"]},"CompanyDocumentTypeDto":{"type":"object","properties":{"id":{"type":"string","format":"uuid"},"name":{"type":"string"},"type":{"type":"string"}},"required":["id","name","type"]},"ResolveDocumentDto":{"type":"object","properties":{"companyId":{"type":"string","format":"uuid"},"canonicalUrl":{"type":"string","format":"uri","example":"/api/v1/companies/{companyId}/documents/{docId}"}},"required":["companyId","canonicalUrl"]}}}}