@icure/api 8.8.6 → 8.9.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (67) hide show
  1. package/icc-api/api/IccAccesslogApi.d.ts +20 -0
  2. package/icc-api/api/IccAccesslogApi.js +41 -0
  3. package/icc-api/api/IccAccesslogApi.js.map +1 -1
  4. package/icc-api/api/IccAgendaApi.d.ts +20 -0
  5. package/icc-api/api/IccAgendaApi.js +41 -0
  6. package/icc-api/api/IccAgendaApi.js.map +1 -1
  7. package/icc-api/api/IccCalendarItemApi.d.ts +20 -0
  8. package/icc-api/api/IccCalendarItemApi.js +41 -0
  9. package/icc-api/api/IccCalendarItemApi.js.map +1 -1
  10. package/icc-api/api/IccCalendarItemTypeApi.d.ts +20 -0
  11. package/icc-api/api/IccCalendarItemTypeApi.js +41 -0
  12. package/icc-api/api/IccCalendarItemTypeApi.js.map +1 -1
  13. package/icc-api/api/IccCodeApi.d.ts +20 -0
  14. package/icc-api/api/IccCodeApi.js +41 -0
  15. package/icc-api/api/IccCodeApi.js.map +1 -1
  16. package/icc-api/api/IccContactApi.d.ts +20 -0
  17. package/icc-api/api/IccContactApi.js +41 -0
  18. package/icc-api/api/IccContactApi.js.map +1 -1
  19. package/icc-api/api/IccDeviceApi.d.ts +20 -0
  20. package/icc-api/api/IccDeviceApi.js +41 -0
  21. package/icc-api/api/IccDeviceApi.js.map +1 -1
  22. package/icc-api/api/IccDocumentApi.d.ts +20 -0
  23. package/icc-api/api/IccDocumentApi.js +41 -0
  24. package/icc-api/api/IccDocumentApi.js.map +1 -1
  25. package/icc-api/api/IccFormApi.d.ts +20 -0
  26. package/icc-api/api/IccFormApi.js +41 -0
  27. package/icc-api/api/IccFormApi.js.map +1 -1
  28. package/icc-api/api/IccHcpartyApi.d.ts +20 -0
  29. package/icc-api/api/IccHcpartyApi.js +41 -0
  30. package/icc-api/api/IccHcpartyApi.js.map +1 -1
  31. package/icc-api/api/IccHelementApi.d.ts +20 -0
  32. package/icc-api/api/IccHelementApi.js +41 -0
  33. package/icc-api/api/IccHelementApi.js.map +1 -1
  34. package/icc-api/api/IccInsuranceApi.d.ts +20 -0
  35. package/icc-api/api/IccInsuranceApi.js +41 -0
  36. package/icc-api/api/IccInsuranceApi.js.map +1 -1
  37. package/icc-api/api/IccInvoiceApi.d.ts +20 -0
  38. package/icc-api/api/IccInvoiceApi.js +41 -0
  39. package/icc-api/api/IccInvoiceApi.js.map +1 -1
  40. package/icc-api/api/IccMessageApi.d.ts +20 -0
  41. package/icc-api/api/IccMessageApi.js +41 -0
  42. package/icc-api/api/IccMessageApi.js.map +1 -1
  43. package/icc-api/api/IccPatientApi.d.ts +20 -0
  44. package/icc-api/api/IccPatientApi.js +41 -0
  45. package/icc-api/api/IccPatientApi.js.map +1 -1
  46. package/icc-api/api/IccPlaceApi.d.ts +20 -0
  47. package/icc-api/api/IccPlaceApi.js +41 -0
  48. package/icc-api/api/IccPlaceApi.js.map +1 -1
  49. package/icc-api/api/IccReceiptApi.d.ts +20 -0
  50. package/icc-api/api/IccReceiptApi.js +41 -0
  51. package/icc-api/api/IccReceiptApi.js.map +1 -1
  52. package/icc-api/api/IccTopicApi.d.ts +20 -0
  53. package/icc-api/api/IccTopicApi.js +41 -0
  54. package/icc-api/api/IccTopicApi.js.map +1 -1
  55. package/icc-api/api/IccUserApi.d.ts +20 -0
  56. package/icc-api/api/IccUserApi.js +41 -0
  57. package/icc-api/api/IccUserApi.js.map +1 -1
  58. package/icc-api/model/ConflictResolutionStrategy.d.ts +17 -0
  59. package/icc-api/model/ConflictResolutionStrategy.js +22 -0
  60. package/icc-api/model/ConflictResolutionStrategy.js.map +1 -0
  61. package/icc-api/model/MergeResult.d.ts +33 -0
  62. package/icc-api/model/MergeResult.js +27 -0
  63. package/icc-api/model/MergeResult.js.map +1 -0
  64. package/icc-api/model/models.d.ts +2 -0
  65. package/icc-api/model/models.js +2 -0
  66. package/icc-api/model/models.js.map +1 -1
  67. package/package.json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CAAC,CAAC,MAAM,CAAC,IAAI,SAAG,CAAC,MAAM,CAAC,cAAc,EAAE,kBAAkB,CAAC,CAAC,CAAA;YACvH,OAAO,SAAG,CAAC,WAAW,CAAC,MAAM,EAAE,IAAI,EAAE,OAAO,EAAE,IAAI,EAAE,IAAI,CAAC,SAAS,EAAE,SAAS,EAAE,IAAI,CAAC,sBAAsB,CAAC,cAAc,EAAE,CAAC;iBACzH,IAAI,CAAC,CAAC,GAAG,EAAE,EAAE,CAAC,IAAI,mDAAwB,CAAU,GAAG,CAAC,IAAI,EAAE,CAAC,CAAC,EAAE,EAAE,CAAC,IAAI,iBAAO,CAAC,CAAC,CAAC,CAAC,CAAC;iBACrF,KAAK,CAAC,CAAC,GAAG,EAAE,EAAE,CAAC,IAAI,CAAC,WAAW,CAAC,GAAG,CAAC,CAAC,CAAA;QAC1C,CAAC;KAAA;CACF;AAj9BD,sCAi9BC","sourcesContent":["/**\n * iCure Data Stack API Documentation\n * The iCure Data Stack Application API is the native interface to iCure. This version is obsolete, please use v2.\n *\n * OpenAPI spec version: v1\n *\n *\n * NOTE: This class is auto generated by the swagger code generator program.\n * https://github.com/swagger-api/swagger-codegen.git\n * Do not edit the class manually.\n */\nimport { XHR } from './XHR'\nimport { AbstractFilterPatient } from '../model/AbstractFilterPatient'\nimport { Content } from '../model/Content'\nimport { DataOwnerRegistrationSuccess } from '../model/DataOwnerRegistrationSuccess'\nimport { Delegation } from '../model/Delegation'\nimport { DocIdentifier } from '../model/DocIdentifier'\nimport { FilterChainPatient } from '../model/FilterChainPatient'\nimport { IdWithRev } from '../model/IdWithRev'\nimport { ListOfIds } from '../model/ListOfIds'\nimport { PaginatedListPatient } from '../model/PaginatedListPatient'\nimport { PaginatedListString } from '../model/PaginatedListString'\nimport { Patient } from '../model/Patient'\nimport { AuthenticationProvider, NoAuthenticationProvider } from '../../icc-x-api/auth/AuthenticationProvider'\nimport { iccRestApiPath } from './IccRestApiPath'\nimport { EntityBulkShareResult } from '../model/requests/EntityBulkShareResult'\nimport { BulkShareOrUpdateMetadataParams } from '../model/requests/BulkShareOrUpdateMetadataParams'\nimport { TimingInfo } from '../model/TimingInfo'\nimport { ConflictResolutionRequest } from '../model/ConflictResolutionRequest'\nimport { ConflictResolutionResult } from '../model/ConflictResolutionResult'\n\nexport class IccPatientApi {\n host: string\n _headers: Array<XHR.Header>\n authenticationProvider: AuthenticationProvider\n fetchImpl?: (input: RequestInfo, init?: RequestInit) => Promise<Response>\n\n get headers(): Promise<Array<XHR.Header>> {\n return Promise.resolve(this._headers)\n }\n\n constructor(\n host: string,\n headers: any,\n authenticationProvider?: AuthenticationProvider,\n fetchImpl?: (input: RequestInfo, init?: RequestInit) => Promise<Response>\n ) {\n this.host = iccRestApiPath(host)\n this._headers = Object.keys(headers).map((k) => new XHR.Header(k, headers[k]))\n this.authenticationProvider = !!authenticationProvider ? authenticationProvider : new NoAuthenticationProvider()\n this.fetchImpl = fetchImpl\n }\n setHeaders(h: Array<XHR.Header>) {\n this._headers = h\n }\n\n handleError(e: XHR.XHRError): never {\n throw e\n }\n\n /**\n * Returns the id and _rev of created patients\n * @summary Create patients in bulk\n * @param body\n */\n async bulkCreatePatients(body?: Array<Patient>): Promise<Array<IdWithRev>> {\n let _body = null\n _body = body\n\n const _url = this.host + `/patient/batch` + '?ts=' + new Date().getTime()\n let headers = await this.headers\n headers = headers.filter((h) => h.header !== 'Content-Type').concat(new XHR.Header('Content-Type', 'application/json'))\n return XHR.sendCommand('POST', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => (doc.body as Array<JSON>).map((it) => new IdWithRev(it)))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * Returns the id and _rev of modified patients\n * @summary Modify patients in bulk\n * @param body\n */\n async bulkUpdatePatients(body?: Array<Patient>): Promise<Array<IdWithRev>> {\n let _body = null\n _body = body\n\n const _url = this.host + `/patient/batch` + '?ts=' + new Date().getTime()\n let headers = await this.headers\n headers = headers.filter((h) => h.header !== 'Content-Type').concat(new XHR.Header('Content-Type', 'application/json'))\n return XHR.sendCommand('PUT', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => (doc.body as Array<JSON>).map((it) => new IdWithRev(it)))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * Returns the count of patients shared directly with the provided hcp (ignoring hierarchies).\n * WARNING: the current implementation can count some patients twice if they have both security metadata and legacy\n * delegations from before v8.\n */\n async countOfPatients(hcPartyId: string): Promise<Content> {\n let _body = null\n\n const _url = this.host + `/patient/hcParty/${encodeURIComponent(String(hcPartyId))}/count` + '?ts=' + new Date().getTime()\n let headers = await this.headers\n return XHR.sendCommand('GET', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => new Content(doc.body as JSON))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * Name, last name, date of birth, and gender are required. After creation of the patient and obtaining the ID, you need to create an initial delegation.\n * @summary Create a patient\n * @param body\n */\n async createPatient(body?: Patient): Promise<Patient> {\n const _url = this.host + `/patient` + '?ts=' + new Date().getTime()\n let headers = await this.headers\n headers = headers.filter((h) => h.header !== 'Content-Type').concat(new XHR.Header('Content-Type', 'application/json'))\n return XHR.sendCommand('POST', _url, headers, body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => new Patient(doc.body as JSON))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * @summary Deletes a batch of patients.\n *\n * @param patientIds a ListOfIds containing the ids of the patients to delete.\n * @return a Promise that will resolve in an array of DocIdentifiers of the successfully deleted patients.\n */\n async deletePatients(patientIds: ListOfIds): Promise<Array<DocIdentifier>> {\n const headers = (await this.headers).filter((h) => h.header !== 'Content-Type').concat(new XHR.Header('Content-Type', 'application/json'))\n return XHR.sendCommand(\n 'POST',\n this.host + `/patient/delete/batch` + '?ts=' + new Date().getTime(),\n headers,\n patientIds,\n this.fetchImpl,\n undefined,\n this.authenticationProvider.getAuthService()\n )\n .then((doc) => (doc.body as Array<JSON>).map((it) => new DocIdentifier(it)))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * @summary Deletes a single patient by id.\n *\n * @param patientId the id of the patient to delete.\n * @return a Promise that will resolve in the DocIdentifier of the deleted patient.\n */\n async deletePatient(patientId: string): Promise<DocIdentifier> {\n return XHR.sendCommand(\n 'DELETE',\n this.host + `/patient/${encodeURIComponent(patientId)}` + '?ts=' + new Date().getTime(),\n await this.headers,\n null,\n this.fetchImpl,\n undefined,\n this.authenticationProvider.getAuthService()\n )\n .then((doc) => new DocIdentifier(doc.body))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * Returns a list of patients along with next start keys and Document ID. If the nextStartKey is Null it means that this is the last page.\n * @summary Filter patients for the current user (HcParty)\n * @param body\n * @param startKey The start key for pagination, depends on the filters used\n * @param startDocumentId A patient document ID\n * @param limit Number of rows\n * @param skip Skip rows\n * @param sort Sort key\n * @param desc Descending\n * @param collectTiming if true, include server-side filter timing information in the response\n */\n filterPatientsBy(\n startKey?: string,\n startDocumentId?: string,\n limit?: number,\n skip?: number,\n sort?: string,\n desc?: boolean,\n body?: FilterChainPatient,\n collectTiming?: false\n ): Promise<PaginatedListPatient>\n filterPatientsBy(\n startKey?: string,\n startDocumentId?: string,\n limit?: number,\n skip?: number,\n sort?: string,\n desc?: boolean,\n body?: FilterChainPatient,\n collectTiming?: true\n ): Promise<PaginatedListPatient & TimingInfo>\n async filterPatientsBy(\n startKey?: string,\n startDocumentId?: string,\n limit?: number,\n skip?: number,\n sort?: string,\n desc?: boolean,\n body?: FilterChainPatient,\n collectTiming: boolean = false\n ): Promise<PaginatedListPatient> {\n let _body = null\n _body = body\n\n const _url =\n this.host +\n `/patient/filter` +\n '?ts=' +\n new Date().getTime() +\n (startKey ? '&startKey=' + encodeURIComponent(String(startKey)) : '') +\n (startDocumentId ? '&startDocumentId=' + encodeURIComponent(String(startDocumentId)) : '') +\n (limit ? '&limit=' + encodeURIComponent(String(limit)) : '') +\n (skip ? '&skip=' + encodeURIComponent(String(skip)) : '') +\n (sort ? '&sort=' + encodeURIComponent(String(sort)) : '') +\n (desc ? '&desc=' + encodeURIComponent(String(desc)) : '')\n let headers = await this.headers\n headers = headers.filter((h) => h.header !== 'Content-Type').concat(new XHR.Header('Content-Type', 'application/json'))\n return XHR.sendCommand(\n 'POST',\n _url,\n headers,\n _body,\n this.fetchImpl,\n undefined,\n this.authenticationProvider.getAuthService(),\n undefined,\n false,\n collectTiming ? ['x-filter-timing-*'] : []\n )\n .then((doc) => Object.assign(new PaginatedListPatient(doc.body as JSON), collectTiming ? { responseHeaders: doc.responseHeaders } : {}))\n .catch((err) => this.handleError(err))\n }\n\n /**\n *\n * @summary Get Paginated List of Patients sorted by Access logs descending\n * @param userId A User ID\n * @param accessType The type of access (COMPUTER or USER)\n * @param startDate The start search epoch\n * @param startKey The start key for pagination\n * @param startDocumentId A patient document ID\n * @param limit Number of rows\n */\n async findByAccessLogUserAfterDate(\n userId: string,\n accessType?: string,\n startDate?: number,\n startKey?: string,\n startDocumentId?: string,\n limit?: number\n ): Promise<PaginatedListPatient> {\n let _body = null\n\n const _url =\n this.host +\n `/patient/byAccess/${encodeURIComponent(String(userId))}` +\n '?ts=' +\n new Date().getTime() +\n (accessType ? '&accessType=' + encodeURIComponent(String(accessType)) : '') +\n (startDate ? '&startDate=' + encodeURIComponent(String(startDate)) : '') +\n (startKey ? '&startKey=' + encodeURIComponent(String(startKey)) : '') +\n (startDocumentId ? '&startDocumentId=' + encodeURIComponent(String(startDocumentId)) : '') +\n (limit ? '&limit=' + encodeURIComponent(String(limit)) : '')\n let headers = await this.headers\n return XHR.sendCommand('GET', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => new PaginatedListPatient(doc.body as JSON))\n .catch((err) => this.handleError(err))\n }\n\n /**\n *\n * @summary Get the patient having the provided externalId\n * @param externalId A external ID\n */\n async findByExternalId(externalId: string): Promise<Patient> {\n let _body = null\n\n const _url = this.host + `/patient/byExternalId/${encodeURIComponent(String(externalId))}` + '?ts=' + new Date().getTime()\n let headers = await this.headers\n return XHR.sendCommand('GET', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => new Patient(doc.body as JSON))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * Returns a list of patients along with next start keys and Document ID. If the nextStartKey is Null it means that this is the last page.\n * @summary Find patients for the current user (HcParty)\n * @param healthcarePartyId HealthcareParty Id. If not set, will use user&#x27;s hcpId\n * @param filterValue Optional value for filtering results\n * @param startKey The start key for pagination: a JSON representation of an array containing all the necessary components to form the Complex Key&#x27;s startKey\n * @param startDocumentId A patient document ID\n * @param limit Number of rows\n * @param sortDirection Optional value for providing a sorting direction (&#x27;asc&#x27;, &#x27;desc&#x27;). Set to &#x27;asc&#x27; by default.\n */\n async findByNameBirthSsinAuto(\n healthcarePartyId?: string,\n filterValue?: string,\n startKey?: string,\n startDocumentId?: string,\n limit?: number,\n sortDirection?: string\n ): Promise<PaginatedListPatient> {\n let _body = null\n\n const _url =\n this.host +\n `/patient/byNameBirthSsinAuto` +\n '?ts=' +\n new Date().getTime() +\n (healthcarePartyId ? '&healthcarePartyId=' + encodeURIComponent(String(healthcarePartyId)) : '') +\n (filterValue ? '&filterValue=' + encodeURIComponent(String(filterValue)) : '') +\n (startKey ? '&startKey=' + encodeURIComponent(String(startKey)) : '') +\n (startDocumentId ? '&startDocumentId=' + encodeURIComponent(String(startDocumentId)) : '') +\n (limit ? '&limit=' + encodeURIComponent(String(limit)) : '') +\n (sortDirection ? '&sortDirection=' + encodeURIComponent(String(sortDirection)) : '')\n let headers = await this.headers\n return XHR.sendCommand('GET', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => new PaginatedListPatient(doc.body as JSON))\n .catch((err) => this.handleError(err))\n }\n\n /**\n *\n * @summary Provides a paginated list of patients with duplicate name for an hecparty\n * @param hcPartyId Healthcare party id\n * @param startKey The start key for pagination, depends on the filters used\n * @param startDocumentId A patient document ID\n * @param limit Number of rows\n */\n async findDuplicatesByName(hcPartyId: string, startKey?: string, startDocumentId?: string, limit?: number): Promise<PaginatedListPatient> {\n let _body = null\n\n const _url =\n this.host +\n `/patient/duplicates/name` +\n '?ts=' +\n new Date().getTime() +\n (hcPartyId ? '&hcPartyId=' + encodeURIComponent(String(hcPartyId)) : '') +\n (startKey ? '&startKey=' + encodeURIComponent(String(startKey)) : '') +\n (startDocumentId ? '&startDocumentId=' + encodeURIComponent(String(startDocumentId)) : '') +\n (limit ? '&limit=' + encodeURIComponent(String(limit)) : '')\n let headers = await this.headers\n return XHR.sendCommand('POST', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => new PaginatedListPatient(doc.body as JSON))\n .catch((err) => this.handleError(err))\n }\n\n /**\n *\n * @summary Provides a paginated list of patients with duplicate ssin for an hecparty\n * @param hcPartyId Healthcare party id\n * @param startKey The start key for pagination, depends on the filters used\n * @param startDocumentId A patient document ID\n * @param limit Number of rows\n */\n async findDuplicatesBySsin(hcPartyId: string, startKey?: string, startDocumentId?: string, limit?: number): Promise<PaginatedListPatient> {\n let _body = null\n\n const _url =\n this.host +\n `/patient/duplicates/ssin` +\n '?ts=' +\n new Date().getTime() +\n (hcPartyId ? '&hcPartyId=' + encodeURIComponent(String(hcPartyId)) : '') +\n (startKey ? '&startKey=' + encodeURIComponent(String(startKey)) : '') +\n (startDocumentId ? '&startDocumentId=' + encodeURIComponent(String(startDocumentId)) : '') +\n (limit ? '&limit=' + encodeURIComponent(String(limit)) : '')\n let headers = await this.headers\n return XHR.sendCommand('POST', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => new PaginatedListPatient(doc.body as JSON))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * Returns a list of patients\n * @summary Filter patients for the current user (HcParty)\n * @param firstName The first name\n * @param lastName The last name\n * @param dateOfBirth The date of birth\n */\n async fuzzySearch(firstName?: string, lastName?: string, dateOfBirth?: number): Promise<Array<Patient>> {\n let _body = null\n\n const _url =\n this.host +\n `/patient/fuzzy` +\n '?ts=' +\n new Date().getTime() +\n (firstName ? '&firstName=' + encodeURIComponent(String(firstName)) : '') +\n (lastName ? '&lastName=' + encodeURIComponent(String(lastName)) : '') +\n (dateOfBirth ? '&dateOfBirth=' + encodeURIComponent(String(dateOfBirth)) : '')\n let headers = await this.headers\n return XHR.sendCommand('GET', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => (doc.body as Array<JSON>).map((it) => new Patient(it)))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * It gets patient administrative data.\n * @summary Get patient\n * @param patientId\n */\n async getPatient(patientId: string): Promise<Patient> {\n let _body = null\n\n const _url = this.host + `/patient/${encodeURIComponent(String(patientId))}` + '?ts=' + new Date().getTime()\n let headers = await this.headers\n return XHR.sendCommand('GET', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => new Patient(doc.body as JSON))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * (key, value) of the map is as follows: (ID of the owner of the encrypted AES key, encrypted AES keys)\n * @summary Get the HcParty encrypted AES keys indexed by owner.\n * @param patientId\n */\n async getPatientAesExchangeKeysForDelegate(\n patientId: string\n ): Promise<{ [delegatorId: string]: { [delegatorPubKeyFingerprint: string]: { [delegatePubKeyFingerprint: string]: string } } }> {\n let _body = null\n\n const _url = this.host + `/patient/${encodeURIComponent(String(patientId))}/aesExchangeKeys` + '?ts=' + new Date().getTime()\n let headers = await this.headers\n return XHR.sendCommand('GET', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => JSON.parse(JSON.stringify(doc.body)))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * It gets patient administrative data based on the identifier (root & extension) parameters.\n * @summary Get patient by identifier\n * @param hcPartyId\n * @param id\n * @param system\n */\n async getPatientByHealthcarepartyAndIdentifier(hcPartyId: string, id: string, system?: string): Promise<Patient> {\n let _body = null\n\n const _url =\n this.host +\n `/patient/${encodeURIComponent(String(hcPartyId))}/${encodeURIComponent(String(id))}` +\n '?ts=' +\n new Date().getTime() +\n (system ? '&system=' + encodeURIComponent(String(system)) : '')\n let headers = await this.headers\n return XHR.sendCommand('GET', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => new Patient(doc.body as JSON))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * This endpoint is used to recover all keys that have already been created and that can be used to share information with this patient. It returns a map with the following structure: ID of the owner of the encrypted AES key -> encrypted AES key. The returned encrypted AES keys will have to be decrypted using the patient's private key. { \\\"hcparty 1 delegator ID\\\": \\\"AES hcparty key (encrypted using patient public RSA key)\\\" \\\"hcparty 2 delegator ID\\\": \\\"other AES hcparty key (encrypted using patient public RSA key)\\\" }\n * @summary Get the patient (identified by patientId) hcparty keys. Those keys are AES keys (encrypted) used to share information between HCPs and a patient.\n * @param patientId The patient Id for which information is shared\n */\n async getPatientHcPartyKeysForDelegate(patientId: string): Promise<{ [key: string]: string }> {\n let _body = null\n\n const _url = this.host + `/patient/${encodeURIComponent(String(patientId))}/keys` + '?ts=' + new Date().getTime()\n let headers = await this.headers\n return XHR.sendCommand('GET', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => JSON.parse(JSON.stringify(doc.body)))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * It gets patient administrative data.\n * @summary Get patients by id\n * @param body\n */\n async getPatients(body?: ListOfIds): Promise<Array<Patient>> {\n const _url = this.host + `/patient/byIds` + '?ts=' + new Date().getTime()\n let headers = await this.headers\n headers = headers.filter((h) => h.header !== 'Content-Type').concat(new XHR.Header('Content-Type', 'application/json'))\n return XHR.sendCommand('POST', _url, headers, body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => (doc.body as Array<JSON>).map((it) => new Patient(it)))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * Returns a list of deleted patients, within the specified time period, if any.\n * @summary Find deleted patients\n * @param startDate Filter deletions after this date (unix epoch), included\n * @param endDate Filter deletions before this date (unix epoch), included\n * @param startKey the startKey provided by the previous page or undefined for the first page.\n * @param desc Descending\n * @param startDocumentId A patient document ID\n * @param limit Number of rows\n */\n async listDeletedPatients(\n startDate?: number,\n endDate?: number,\n desc?: boolean,\n startKey?: string,\n startDocumentId?: string,\n limit?: number\n ): Promise<PaginatedListPatient> {\n const _url =\n this.host +\n `/patient/deleted/byDate` +\n '?ts=' +\n new Date().getTime() +\n (startDate ? '&startDate=' + encodeURIComponent(startDate) : '') +\n (endDate ? '&endDate=' + encodeURIComponent(endDate) : '') +\n (desc ? '&desc=' + encodeURIComponent(desc) : '') +\n (startKey ? '&startKey=' + encodeURIComponent(startKey) : '') +\n (startDocumentId ? '&startDocumentId=' + encodeURIComponent(startDocumentId) : '') +\n (limit ? '&limit=' + encodeURIComponent(limit) : '')\n let headers = await this.headers\n return XHR.sendCommand('GET', _url, headers, null, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => new PaginatedListPatient(doc.body as JSON))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * Returns a list of deleted patients, by name and/or firstname prefix, if any.\n * @summary Find deleted patients\n * @param firstName First name prefix\n * @param lastName Last name prefix\n */\n async listDeletedPatientsByName(firstName?: string, lastName?: string): Promise<Array<Patient>> {\n let _body = null\n\n const _url =\n this.host +\n `/patient/deleted/by_name` +\n '?ts=' +\n new Date().getTime() +\n (firstName ? '&firstName=' + encodeURIComponent(String(firstName)) : '') +\n (lastName ? '&lastName=' + encodeURIComponent(String(lastName)) : '')\n let headers = await this.headers\n return XHR.sendCommand('GET', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => (doc.body as Array<JSON>).map((it) => new Patient(it)))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * Returns a list of patients that have been merged after the provided date\n * @summary List patients that have been merged towards another patient\n * @param date\n */\n async listOfMergesAfter(date: number): Promise<Array<Patient>> {\n let _body = null\n\n const _url = this.host + `/patient/merges/${encodeURIComponent(String(date))}` + '?ts=' + new Date().getTime()\n let headers = await this.headers\n return XHR.sendCommand('GET', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => (doc.body as Array<JSON>).map((it) => new Patient(it)))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * Returns a list of patients that have been modified after the provided date\n * @summary List patients that have been modified after the provided date\n * @param date\n * @param startKey The start key for pagination the date of the first element of the new page\n * @param startDocumentId A patient document ID\n * @param limit Number of rows\n */\n async listOfPatientsModifiedAfter(date: number, startKey?: number, startDocumentId?: string, limit?: number): Promise<PaginatedListPatient> {\n let _body = null\n\n const _url =\n this.host +\n `/patient/modifiedAfter/${encodeURIComponent(String(date))}` +\n '?ts=' +\n new Date().getTime() +\n (startKey ? '&startKey=' + encodeURIComponent(String(startKey)) : '') +\n (startDocumentId ? '&startDocumentId=' + encodeURIComponent(String(startDocumentId)) : '') +\n (limit ? '&limit=' + encodeURIComponent(String(limit)) : '')\n let headers = await this.headers\n return XHR.sendCommand('GET', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => new PaginatedListPatient(doc.body as JSON))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * @deprecated This method is not intuitive and will be removed in a future version\n * Currently there is no direct replacement that can do everything this method does.\n * If you need all patients unsorted or sorted by ssin/date of birth use `PatientByHcPartyFilter`/`PatientByHcPartyDateOfBirthFilter`\n * with {@link matchPatientsBy} to get the ids of all the patients shared directly with an HCP (ignoring hierarchies).\n * Note that on databases with many patients (>50k) the matches request could take various seconds as it is not\n * paginated.\n * If you want to use pagination or need to sort by name instead you can use the {@link listPatientsSortedByName}.\n * Usage of PatientByHcPartyNameFilter or PatientByHcPartyNameContainsFuzzyFilter as a replacement of this method is\n * discouraged as the sorting done by those filter is unintuitive.\n * Contact us if your use case is not covered by the suggested alternatives.\n *\n * This method returns all the patients (with pagination) that are shared directly with the parent of {@link hcPartyId},\n * or if undefined the current user's parent. Note that this doesn't allow to get patients that are shared only with\n * the current user and not its parent.\n */\n async listPatients(\n hcPartyId?: string,\n sortField?: string,\n startKey?: string,\n startDocumentId?: string,\n limit?: number,\n sortDirection?: string\n ): Promise<PaginatedListPatient> {\n let _body = null\n\n const _url =\n this.host +\n `/patient` +\n '?ts=' +\n new Date().getTime() +\n (hcPartyId ? '&hcPartyId=' + encodeURIComponent(String(hcPartyId)) : '') +\n (sortField ? '&sortField=' + encodeURIComponent(String(sortField)) : '') +\n (startKey ? '&startKey=' + encodeURIComponent(String(startKey)) : '') +\n (startDocumentId ? '&startDocumentId=' + encodeURIComponent(String(startDocumentId)) : '') +\n (limit ? '&limit=' + encodeURIComponent(String(limit)) : '') +\n (sortDirection ? '&sortDirection=' + encodeURIComponent(String(sortDirection)) : '')\n let headers = await this.headers\n return XHR.sendCommand('GET', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => new PaginatedListPatient(doc.body as JSON))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * Get all patients shared directly with the provided hcparty (ignoring hierarchies) sorted by lastName, firstName.\n */\n async listPatientsSortedByName(hcPartyId?: string, startKey?: string, startDocumentId?: string, limit?: number): Promise<PaginatedListPatient> {\n let _body = null\n\n const _url =\n this.host +\n `/patient/byHcPartyId` +\n '?ts=' +\n new Date().getTime() +\n (hcPartyId ? '&hcPartyId=' + encodeURIComponent(String(hcPartyId)) : '') +\n (startKey ? '&startKey=' + encodeURIComponent(String(startKey)) : '') +\n (startDocumentId ? '&startDocumentId=' + encodeURIComponent(String(startDocumentId)) : '') +\n (limit ? '&limit=' + encodeURIComponent(String(limit)) : '')\n let headers = await this.headers\n return XHR.sendCommand('GET', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => new PaginatedListPatient(doc.body as JSON))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * Returns a list of patients along with next start keys and Document ID. If the nextStartKey is Null it means that this is the last page.\n * @summary List patients for a specific HcParty or for the current HcParty\n * @param hcPartyId\n * @param sortField Optional value for sorting results by a given field (&#x27;name&#x27;, &#x27;ssin&#x27;, &#x27;dateOfBirth&#x27;). Specifying this deactivates filtering\n * @param startKey The start key for pagination: a JSON representation of an array containing all the necessary components to form the Complex Key&#x27;s startKey\n * @param startDocumentId A patient document ID\n * @param limit Number of rows\n * @param sortDirection Optional value for providing a sorting direction (&#x27;asc&#x27;, &#x27;desc&#x27;). Set to &#x27;asc&#x27; by default.\n */\n async listPatientsByHcParty(\n hcPartyId: string,\n sortField?: string,\n startKey?: string,\n startDocumentId?: string,\n limit?: number,\n sortDirection?: string\n ): Promise<PaginatedListPatient> {\n let _body = null\n\n const _url =\n this.host +\n `/patient/hcParty/${encodeURIComponent(String(hcPartyId))}` +\n '?ts=' +\n new Date().getTime() +\n (sortField ? '&sortField=' + encodeURIComponent(String(sortField)) : '') +\n (startKey ? '&startKey=' + encodeURIComponent(String(startKey)) : '') +\n (startDocumentId ? '&startDocumentId=' + encodeURIComponent(String(startDocumentId)) : '') +\n (limit ? '&limit=' + encodeURIComponent(String(limit)) : '') +\n (sortDirection ? '&sortDirection=' + encodeURIComponent(String(sortDirection)) : '')\n let headers = await this.headers\n return XHR.sendCommand('GET', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => new PaginatedListPatient(doc.body as JSON))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * Returns a list of patients along with next start keys and Document ID. If the nextStartKey is Null it means that this is the last page.\n * @summary List patients by pages for a specific HcParty\n * @param hcPartyId Healthcare party id\n * @param startKey The page first id\n * @param startDocumentId A patient document ID\n * @param limit Page size\n */\n async listPatientsIds(hcPartyId: string, startKey?: string, startDocumentId?: string, limit?: number): Promise<PaginatedListString> {\n let _body = null\n\n const _url =\n this.host +\n `/patient/byHcPartyId` +\n '?ts=' +\n new Date().getTime() +\n (hcPartyId ? '&hcPartyId=' + encodeURIComponent(String(hcPartyId)) : '') +\n (startKey ? '&startKey=' + encodeURIComponent(String(startKey)) : '') +\n (startDocumentId ? '&startDocumentId=' + encodeURIComponent(String(startDocumentId)) : '') +\n (limit ? '&limit=' + encodeURIComponent(String(limit)) : '')\n let headers = await this.headers\n return XHR.sendCommand('GET', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => new PaginatedListString(doc.body as JSON))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * Returns a list of patients along with next start keys and Document ID. If the nextStartKey is Null it means that this is the last page.\n * @summary List patients of a specific HcParty or of the current HcParty\n * @param hcPartyId\n * @param sortField Optional value for sorting results by a given field (&#x27;name&#x27;, &#x27;ssin&#x27;, &#x27;dateOfBirth&#x27;). Specifying this deactivates filtering\n * @param startKey The start key for pagination: a JSON representation of an array containing all the necessary components to form the Complex Key&#x27;s startKey\n * @param startDocumentId A patient document ID\n * @param limit Number of rows\n * @param sortDirection Optional value for providing a sorting direction (&#x27;asc&#x27;, &#x27;desc&#x27;). Set to &#x27;asc&#x27; by default.\n */\n async listPatientsOfHcParty(\n hcPartyId: string,\n sortField?: string,\n startKey?: string,\n startDocumentId?: string,\n limit?: number,\n sortDirection?: string\n ): Promise<PaginatedListPatient> {\n let _body = null\n\n const _url =\n this.host +\n `/patient/ofHcParty/${encodeURIComponent(String(hcPartyId))}` +\n '?ts=' +\n new Date().getTime() +\n (sortField ? '&sortField=' + encodeURIComponent(String(sortField)) : '') +\n (startKey ? '&startKey=' + encodeURIComponent(String(startKey)) : '') +\n (startDocumentId ? '&startDocumentId=' + encodeURIComponent(String(startDocumentId)) : '') +\n (limit ? '&limit=' + encodeURIComponent(String(limit)) : '') +\n (sortDirection ? '&sortDirection=' + encodeURIComponent(String(sortDirection)) : '')\n let headers = await this.headers\n return XHR.sendCommand('GET', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => new PaginatedListPatient(doc.body as JSON))\n .catch((err) => this.handleError(err))\n }\n\n /**\n *\n * @summary Get ids of patients matching the provided filter for the current user (HcParty)\n * @param body\n * @param collectTiming if true, include server-side filter timing information in the response\n */\n matchPatientsBy(body?: AbstractFilterPatient, collectTiming?: false): Promise<Array<string>>\n matchPatientsBy(body?: AbstractFilterPatient, collectTiming?: true): Promise<Array<string> & TimingInfo>\n async matchPatientsBy(body?: AbstractFilterPatient, collectTiming: boolean = false): Promise<Array<string>> {\n const _url = this.host + `/patient/match` + '?ts=' + new Date().getTime()\n let headers = await this.headers\n headers = headers.filter((h) => h.header !== 'Content-Type').concat(new XHR.Header('Content-Type', 'application/json'))\n return XHR.sendCommand(\n 'POST',\n _url,\n headers,\n body,\n this.fetchImpl,\n undefined,\n this.authenticationProvider.getAuthService(),\n undefined,\n false,\n collectTiming ? ['x-filter-timing-*'] : []\n )\n .then((doc) =>\n Object.assign(\n (doc.body as Array<JSON>).map((it) => JSON.parse(JSON.stringify(it))),\n collectTiming ? { responseHeaders: doc.responseHeaders } : {}\n )\n )\n .catch((err) => this.handleError(err))\n }\n\n /**\n *\n * @summary Merge a series of patients into another patient\n * @param toId\n * @param fromIds\n */\n async mergeInto(toId: string, fromIds: string): Promise<Patient> {\n let _body = null\n\n const _url =\n this.host + `/patient/mergeInto/${encodeURIComponent(String(toId))}/from/${encodeURIComponent(String(fromIds))}` + '?ts=' + new Date().getTime()\n let headers = await this.headers\n return XHR.sendCommand('PUT', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => new Patient(doc.body as JSON))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * No particular return value. It's just a message.\n * @summary Modify a patient\n * @param body\n */\n async modifyPatient(body?: Patient): Promise<Patient> {\n let _body = null\n _body = body\n\n const _url = this.host + `/patient` + '?ts=' + new Date().getTime()\n let headers = await this.headers\n headers = headers.filter((h) => h.header !== 'Content-Type').concat(new XHR.Header('Content-Type', 'application/json'))\n return XHR.sendCommand('PUT', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => new Patient(doc.body as JSON))\n .catch((err) => this.handleError(err))\n }\n\n /**\n *\n * @summary Set a patient referral doctor\n * @param patientId\n * @param referralId The referal id. Accepts &#x27;none&#x27; for referral removal.\n * @param start Optional value for start of referral\n * @param end Optional value for end of referral\n */\n async modifyPatientReferral(patientId: string, referralId: string, start?: number, end?: number): Promise<Patient> {\n let _body = null\n\n const _url =\n this.host +\n `/patient/${encodeURIComponent(String(patientId))}/referral/${encodeURIComponent(String(referralId))}` +\n '?ts=' +\n new Date().getTime() +\n (start ? '&start=' + encodeURIComponent(String(start)) : '') +\n (end ? '&end=' + encodeURIComponent(String(end)) : '')\n let headers = await this.headers\n return XHR.sendCommand('PUT', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => new Patient(doc.body as JSON))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * Register a new patient into the system\n * @summary Register a patient\n * @param body\n * @param hcPartyId\n * @param groupId\n * @param token\n * @param useShortToken\n */\n async registerPatient(\n hcPartyId: string,\n groupId: string,\n token?: string,\n useShortToken?: boolean,\n body?: Patient\n ): Promise<DataOwnerRegistrationSuccess> {\n let _body = null\n _body = body\n\n const _url =\n this.host +\n `/patient/register/forHcp/${encodeURIComponent(String(hcPartyId))}/inGroup/${encodeURIComponent(String(groupId))}` +\n '?ts=' +\n new Date().getTime() +\n (token ? '&token=' + encodeURIComponent(String(token)) : '') +\n (useShortToken ? '&useShortToken=' + encodeURIComponent(String(useShortToken)) : '')\n let headers = await this.headers\n headers = headers.filter((h) => h.header !== 'Content-Type').concat(new XHR.Header('Content-Type', 'application/json'))\n return XHR.sendCommand('POST', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => new DataOwnerRegistrationSuccess(doc.body as JSON))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * Response is an array containing the ID of undeleted patient..\n * @summary undelete previously deleted patients\n * @param patientIds\n */\n async undeletePatient(patientIds: string): Promise<Array<DocIdentifier>> {\n let _body = null\n\n const _url = this.host + `/patient/undelete/${encodeURIComponent(String(patientIds))}` + '?ts=' + new Date().getTime()\n let headers = await this.headers\n return XHR.sendCommand('PUT', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => (doc.body as Array<JSON>).map((it) => new DocIdentifier(it)))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * @internal this method is for internal use only and may be changed without notice\n */\n async bulkSharePatients(request: BulkShareOrUpdateMetadataParams): Promise<EntityBulkShareResult<Patient>[]> {\n const _url = this.host + '/patient/bulkSharedMetadataUpdate' + '?ts=' + new Date().getTime()\n let headers = await this.headers\n headers = headers.filter((h) => h.header !== 'Content-Type').concat(new XHR.Header('Content-Type', 'application/json'))\n return XHR.sendCommand('PUT', _url, headers, request, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => (doc.body as Array<JSON>).map((x) => new EntityBulkShareResult<Patient>(x, Patient)))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * @internal use mergePatients from the extended api instead\n */\n async baseMergePatients(fromId: string, expectedFromRev: string, updatedInto: Patient) {\n let _body = updatedInto\n\n const _url =\n this.host +\n `/patient/mergeInto/${encodeURIComponent(String(updatedInto.id))}/from/${encodeURIComponent(String(fromId))}` +\n '?ts=' +\n new Date().getTime() +\n '&expectedFromRev=' +\n encodeURIComponent(String(expectedFromRev))\n let headers = await this.headers\n headers = headers.filter((h) => h.header !== 'Content-Type').concat(new XHR.Header('Content-Type', 'application/json'))\n return XHR.sendCommand('PUT', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => new Patient(doc.body as JSON))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * Retrieves the ids of all the patients that currently have conflicting revisions and therefore need to\n * be resolved.\n * @summary List the ids of the patients that have conflicts.\n * @return the ids of the patients with unresolved conflicts.\n */\n async getConflictingEntitiesIds(): Promise<Array<string>> {\n const _url = this.host + `/patient/conflicts` + '?ts=' + new Date().getTime()\n let headers = await this.headers\n return XHR.sendCommand('GET', _url, headers, null, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => doc.body as Array<string>)\n .catch((err) => this.handleError(err))\n }\n\n /**\n * Retrieves all the conflicting revisions of the patient with the given id (the current revision is not\n * included). The returned entities are still encrypted.\n * @summary Get the conflicting revisions of a patient.\n * @param entityId the id of the patient to retrieve the conflicts for.\n * @return the conflicting revisions of the patient.\n */\n async getConflictsForEntity(entityId: string): Promise<Array<Patient>> {\n const _url = this.host + `/patient/conflicts/of?entityId=${encodeURIComponent(String(entityId))}` + '&ts=' + new Date().getTime()\n let headers = await this.headers\n return XHR.sendCommand('GET', _url, headers, null, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => (doc.body as Array<JSON>).map((it) => new Patient(it)))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * Resolves a conflict by declaring which revision of the patient should be kept as winner and which\n * conflicting revisions should be purged. The provided document must already be encrypted.\n * @summary Declare the winning revision of a conflicting patient.\n * @param body the {@link ConflictResolutionRequest} carrying the winning revision and the conflicts to purge.\n * @return the {@link ConflictResolutionResult} with the saved winner and the conflicts that are still unresolved.\n */\n async declareConflictWinner(body: ConflictResolutionRequest<Patient>): Promise<ConflictResolutionResult<Patient>> {\n const _url = this.host + `/patient/conflicts/winner` + '?ts=' + new Date().getTime()\n let headers = await this.headers\n headers = headers.filter((h) => h.header !== 'Content-Type').concat(new XHR.Header('Content-Type', 'application/json'))\n return XHR.sendCommand('POST', _url, headers, body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => new ConflictResolutionResult<Patient>(doc.body, (x) => new Patient(x)))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * Like {@link getConflictingEntitiesIds} but targets the entities of the group with the given id.\n * @summary List the ids of the patients that have conflicts, in the given group.\n * @param groupId the id of the group to look into.\n * @return the ids of the patients with unresolved conflicts in the group.\n */\n async getConflictingEntitiesIdsInGroup(groupId: string): Promise<Array<string>> {\n const _url = this.host + `/patient/inGroup/${encodeURIComponent(String(groupId))}/conflicts` + '?ts=' + new Date().getTime()\n let headers = await this.headers\n return XHR.sendCommand('GET', _url, headers, null, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => doc.body as Array<string>)\n .catch((err) => this.handleError(err))\n }\n\n /**\n * Like {@link getConflictsForEntity} but targets the entity of the group with the given id.\n * @summary Get the conflicting revisions of a patient, in the given group.\n * @param groupId the id of the group the patient belongs to.\n * @param entityId the id of the patient to retrieve the conflicts for.\n * @return the conflicting revisions of the patient.\n */\n async getConflictsForEntityInGroup(groupId: string, entityId: string): Promise<Array<Patient>> {\n const _url =\n this.host +\n `/patient/inGroup/${encodeURIComponent(String(groupId))}/conflicts/of?entityId=${encodeURIComponent(String(entityId))}` +\n '&ts=' +\n new Date().getTime()\n let headers = await this.headers\n return XHR.sendCommand('GET', _url, headers, null, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => (doc.body as Array<JSON>).map((it) => new Patient(it)))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * Like {@link declareConflictWinner} but targets the entity of the group with the given id.\n * @summary Declare the winning revision of a conflicting patient, in the given group.\n * @param groupId the id of the group the patient belongs to.\n * @param body the {@link ConflictResolutionRequest} carrying the winning revision and the conflicts to purge.\n * @return the {@link ConflictResolutionResult} with the saved winner and the conflicts that are still unresolved.\n */\n async declareConflictWinnerInGroup(groupId: string, body: ConflictResolutionRequest<Patient>): Promise<ConflictResolutionResult<Patient>> {\n const _url = this.host + `/patient/inGroup/${encodeURIComponent(String(groupId))}/conflicts/winner` + '?ts=' + new Date().getTime()\n let headers = await this.headers\n headers = headers.filter((h) => h.header !== 'Content-Type').concat(new XHR.Header('Content-Type', 'application/json'))\n return XHR.sendCommand('POST', _url, headers, body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => new ConflictResolutionResult<Patient>(doc.body, (x) => new Patient(x)))\n .catch((err) => this.handleError(err))\n }\n}\n"]}
1
+ {"version":3,"file":"IccPatientApi.js","sourceRoot":"","sources":["../../../icc-api/api/IccPatientApi.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA;;;;;;;;;;GAUG;AACH,+BAA2B;AAE3B,8CAA0C;AAC1C,wFAAoF;AAEpF,0DAAsD;AAEtD,kDAA8C;AAE9C,wEAAoE;AACpE,sEAAkE;AAClE,8CAA0C;AAC1C,wFAA8G;AAC9G,qDAAiD;AACjD,mFAA+E;AAI/E,gFAA4E;AAC5E,oFAAgF;AAChF,sDAAkD;AAElD,MAAa,aAAa;IAMxB,IAAI,OAAO;QACT,OAAO,OAAO,CAAC,OAAO,CAAC,IAAI,CAAC,QAAQ,CAAC,CAAA;IACvC,CAAC;IAED,YACE,IAAY,EACZ,OAAY,EACZ,sBAA+C,EAC/C,SAAyE;QAEzE,IAAI,CAAC,IAAI,GAAG,IAAA,+BAAc,EAAC,IAAI,CAAC,CAAA;QAChC,IAAI,CAAC,QAAQ,GAAG,MAAM,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,IAAI,SAAG,CAAC,MAAM,CAAC,CAAC,EAAE,OAAO,CAAC,CAAC,CAAC,CAAC,CAAC,CAAA;QAC9E,IAAI,CAAC,sBAAsB,GAAG,CAAC,CAAC,sBAAsB,CAAC,CAAC,CAAC,sBAAsB,CAAC,CAAC,CAAC,IAAI,iDAAwB,EAAE,CAAA;QAChH,IAAI,CAAC,SAAS,GAAG,SAAS,CAAA;IAC5B,CAAC;IACD,UAAU,CAAC,CAAoB;QAC7B,IAAI,CAAC,QAAQ,GAAG,CAAC,CAAA;IACnB,CAAC;IAED,WAAW,CAAC,CAAe;QACzB,MAAM,CAAC,CAAA;IACT,CAAC;IAED;;;;OAIG;IACG,kBAAkB,CAAC,IAAqB;;YAC5C,IAAI,KA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C;iBACzE,KAAK,CAAC,CAAC,GAAG,EAAE,EAAE,CAAC,IAAI,CAAC,WAAW,CAAC,GAAG,CAAC,CAAC,CAAA;QAC1C,CAAC;KAAA;CACF;AA9/BD,sCA8/BC","sourcesContent":["/**\n * iCure Data Stack API Documentation\n * The iCure Data Stack Application API is the native interface to iCure. This version is obsolete, please use v2.\n *\n * OpenAPI spec version: v1\n *\n *\n * NOTE: This class is auto generated by the swagger code generator program.\n * https://github.com/swagger-api/swagger-codegen.git\n * Do not edit the class manually.\n */\nimport { XHR } from './XHR'\nimport { AbstractFilterPatient } from '../model/AbstractFilterPatient'\nimport { Content } from '../model/Content'\nimport { DataOwnerRegistrationSuccess } from '../model/DataOwnerRegistrationSuccess'\nimport { Delegation } from '../model/Delegation'\nimport { DocIdentifier } from '../model/DocIdentifier'\nimport { FilterChainPatient } from '../model/FilterChainPatient'\nimport { IdWithRev } from '../model/IdWithRev'\nimport { ListOfIds } from '../model/ListOfIds'\nimport { PaginatedListPatient } from '../model/PaginatedListPatient'\nimport { PaginatedListString } from '../model/PaginatedListString'\nimport { Patient } from '../model/Patient'\nimport { AuthenticationProvider, NoAuthenticationProvider } from '../../icc-x-api/auth/AuthenticationProvider'\nimport { iccRestApiPath } from './IccRestApiPath'\nimport { EntityBulkShareResult } from '../model/requests/EntityBulkShareResult'\nimport { BulkShareOrUpdateMetadataParams } from '../model/requests/BulkShareOrUpdateMetadataParams'\nimport { TimingInfo } from '../model/TimingInfo'\nimport { ConflictResolutionRequest } from '../model/ConflictResolutionRequest'\nimport { ConflictResolutionResult } from '../model/ConflictResolutionResult'\nimport { ConflictResolutionStrategy } from '../model/ConflictResolutionStrategy'\nimport { MergeResult } from '../model/MergeResult'\n\nexport class IccPatientApi {\n host: string\n _headers: Array<XHR.Header>\n authenticationProvider: AuthenticationProvider\n fetchImpl?: (input: RequestInfo, init?: RequestInit) => Promise<Response>\n\n get headers(): Promise<Array<XHR.Header>> {\n return Promise.resolve(this._headers)\n }\n\n constructor(\n host: string,\n headers: any,\n authenticationProvider?: AuthenticationProvider,\n fetchImpl?: (input: RequestInfo, init?: RequestInit) => Promise<Response>\n ) {\n this.host = iccRestApiPath(host)\n this._headers = Object.keys(headers).map((k) => new XHR.Header(k, headers[k]))\n this.authenticationProvider = !!authenticationProvider ? authenticationProvider : new NoAuthenticationProvider()\n this.fetchImpl = fetchImpl\n }\n setHeaders(h: Array<XHR.Header>) {\n this._headers = h\n }\n\n handleError(e: XHR.XHRError): never {\n throw e\n }\n\n /**\n * Returns the id and _rev of created patients\n * @summary Create patients in bulk\n * @param body\n */\n async bulkCreatePatients(body?: Array<Patient>): Promise<Array<IdWithRev>> {\n let _body = null\n _body = body\n\n const _url = this.host + `/patient/batch` + '?ts=' + new Date().getTime()\n let headers = await this.headers\n headers = headers.filter((h) => h.header !== 'Content-Type').concat(new XHR.Header('Content-Type', 'application/json'))\n return XHR.sendCommand('POST', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => (doc.body as Array<JSON>).map((it) => new IdWithRev(it)))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * Returns the id and _rev of modified patients\n * @summary Modify patients in bulk\n * @param body\n */\n async bulkUpdatePatients(body?: Array<Patient>): Promise<Array<IdWithRev>> {\n let _body = null\n _body = body\n\n const _url = this.host + `/patient/batch` + '?ts=' + new Date().getTime()\n let headers = await this.headers\n headers = headers.filter((h) => h.header !== 'Content-Type').concat(new XHR.Header('Content-Type', 'application/json'))\n return XHR.sendCommand('PUT', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => (doc.body as Array<JSON>).map((it) => new IdWithRev(it)))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * Returns the count of patients shared directly with the provided hcp (ignoring hierarchies).\n * WARNING: the current implementation can count some patients twice if they have both security metadata and legacy\n * delegations from before v8.\n */\n async countOfPatients(hcPartyId: string): Promise<Content> {\n let _body = null\n\n const _url = this.host + `/patient/hcParty/${encodeURIComponent(String(hcPartyId))}/count` + '?ts=' + new Date().getTime()\n let headers = await this.headers\n return XHR.sendCommand('GET', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => new Content(doc.body as JSON))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * Name, last name, date of birth, and gender are required. After creation of the patient and obtaining the ID, you need to create an initial delegation.\n * @summary Create a patient\n * @param body\n */\n async createPatient(body?: Patient): Promise<Patient> {\n const _url = this.host + `/patient` + '?ts=' + new Date().getTime()\n let headers = await this.headers\n headers = headers.filter((h) => h.header !== 'Content-Type').concat(new XHR.Header('Content-Type', 'application/json'))\n return XHR.sendCommand('POST', _url, headers, body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => new Patient(doc.body as JSON))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * @summary Deletes a batch of patients.\n *\n * @param patientIds a ListOfIds containing the ids of the patients to delete.\n * @return a Promise that will resolve in an array of DocIdentifiers of the successfully deleted patients.\n */\n async deletePatients(patientIds: ListOfIds): Promise<Array<DocIdentifier>> {\n const headers = (await this.headers).filter((h) => h.header !== 'Content-Type').concat(new XHR.Header('Content-Type', 'application/json'))\n return XHR.sendCommand(\n 'POST',\n this.host + `/patient/delete/batch` + '?ts=' + new Date().getTime(),\n headers,\n patientIds,\n this.fetchImpl,\n undefined,\n this.authenticationProvider.getAuthService()\n )\n .then((doc) => (doc.body as Array<JSON>).map((it) => new DocIdentifier(it)))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * @summary Deletes a single patient by id.\n *\n * @param patientId the id of the patient to delete.\n * @return a Promise that will resolve in the DocIdentifier of the deleted patient.\n */\n async deletePatient(patientId: string): Promise<DocIdentifier> {\n return XHR.sendCommand(\n 'DELETE',\n this.host + `/patient/${encodeURIComponent(patientId)}` + '?ts=' + new Date().getTime(),\n await this.headers,\n null,\n this.fetchImpl,\n undefined,\n this.authenticationProvider.getAuthService()\n )\n .then((doc) => new DocIdentifier(doc.body))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * Returns a list of patients along with next start keys and Document ID. If the nextStartKey is Null it means that this is the last page.\n * @summary Filter patients for the current user (HcParty)\n * @param body\n * @param startKey The start key for pagination, depends on the filters used\n * @param startDocumentId A patient document ID\n * @param limit Number of rows\n * @param skip Skip rows\n * @param sort Sort key\n * @param desc Descending\n * @param collectTiming if true, include server-side filter timing information in the response\n */\n filterPatientsBy(\n startKey?: string,\n startDocumentId?: string,\n limit?: number,\n skip?: number,\n sort?: string,\n desc?: boolean,\n body?: FilterChainPatient,\n collectTiming?: false\n ): Promise<PaginatedListPatient>\n filterPatientsBy(\n startKey?: string,\n startDocumentId?: string,\n limit?: number,\n skip?: number,\n sort?: string,\n desc?: boolean,\n body?: FilterChainPatient,\n collectTiming?: true\n ): Promise<PaginatedListPatient & TimingInfo>\n async filterPatientsBy(\n startKey?: string,\n startDocumentId?: string,\n limit?: number,\n skip?: number,\n sort?: string,\n desc?: boolean,\n body?: FilterChainPatient,\n collectTiming: boolean = false\n ): Promise<PaginatedListPatient> {\n let _body = null\n _body = body\n\n const _url =\n this.host +\n `/patient/filter` +\n '?ts=' +\n new Date().getTime() +\n (startKey ? '&startKey=' + encodeURIComponent(String(startKey)) : '') +\n (startDocumentId ? '&startDocumentId=' + encodeURIComponent(String(startDocumentId)) : '') +\n (limit ? '&limit=' + encodeURIComponent(String(limit)) : '') +\n (skip ? '&skip=' + encodeURIComponent(String(skip)) : '') +\n (sort ? '&sort=' + encodeURIComponent(String(sort)) : '') +\n (desc ? '&desc=' + encodeURIComponent(String(desc)) : '')\n let headers = await this.headers\n headers = headers.filter((h) => h.header !== 'Content-Type').concat(new XHR.Header('Content-Type', 'application/json'))\n return XHR.sendCommand(\n 'POST',\n _url,\n headers,\n _body,\n this.fetchImpl,\n undefined,\n this.authenticationProvider.getAuthService(),\n undefined,\n false,\n collectTiming ? ['x-filter-timing-*'] : []\n )\n .then((doc) => Object.assign(new PaginatedListPatient(doc.body as JSON), collectTiming ? { responseHeaders: doc.responseHeaders } : {}))\n .catch((err) => this.handleError(err))\n }\n\n /**\n *\n * @summary Get Paginated List of Patients sorted by Access logs descending\n * @param userId A User ID\n * @param accessType The type of access (COMPUTER or USER)\n * @param startDate The start search epoch\n * @param startKey The start key for pagination\n * @param startDocumentId A patient document ID\n * @param limit Number of rows\n */\n async findByAccessLogUserAfterDate(\n userId: string,\n accessType?: string,\n startDate?: number,\n startKey?: string,\n startDocumentId?: string,\n limit?: number\n ): Promise<PaginatedListPatient> {\n let _body = null\n\n const _url =\n this.host +\n `/patient/byAccess/${encodeURIComponent(String(userId))}` +\n '?ts=' +\n new Date().getTime() +\n (accessType ? '&accessType=' + encodeURIComponent(String(accessType)) : '') +\n (startDate ? '&startDate=' + encodeURIComponent(String(startDate)) : '') +\n (startKey ? '&startKey=' + encodeURIComponent(String(startKey)) : '') +\n (startDocumentId ? '&startDocumentId=' + encodeURIComponent(String(startDocumentId)) : '') +\n (limit ? '&limit=' + encodeURIComponent(String(limit)) : '')\n let headers = await this.headers\n return XHR.sendCommand('GET', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => new PaginatedListPatient(doc.body as JSON))\n .catch((err) => this.handleError(err))\n }\n\n /**\n *\n * @summary Get the patient having the provided externalId\n * @param externalId A external ID\n */\n async findByExternalId(externalId: string): Promise<Patient> {\n let _body = null\n\n const _url = this.host + `/patient/byExternalId/${encodeURIComponent(String(externalId))}` + '?ts=' + new Date().getTime()\n let headers = await this.headers\n return XHR.sendCommand('GET', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => new Patient(doc.body as JSON))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * Returns a list of patients along with next start keys and Document ID. If the nextStartKey is Null it means that this is the last page.\n * @summary Find patients for the current user (HcParty)\n * @param healthcarePartyId HealthcareParty Id. If not set, will use user&#x27;s hcpId\n * @param filterValue Optional value for filtering results\n * @param startKey The start key for pagination: a JSON representation of an array containing all the necessary components to form the Complex Key&#x27;s startKey\n * @param startDocumentId A patient document ID\n * @param limit Number of rows\n * @param sortDirection Optional value for providing a sorting direction (&#x27;asc&#x27;, &#x27;desc&#x27;). Set to &#x27;asc&#x27; by default.\n */\n async findByNameBirthSsinAuto(\n healthcarePartyId?: string,\n filterValue?: string,\n startKey?: string,\n startDocumentId?: string,\n limit?: number,\n sortDirection?: string\n ): Promise<PaginatedListPatient> {\n let _body = null\n\n const _url =\n this.host +\n `/patient/byNameBirthSsinAuto` +\n '?ts=' +\n new Date().getTime() +\n (healthcarePartyId ? '&healthcarePartyId=' + encodeURIComponent(String(healthcarePartyId)) : '') +\n (filterValue ? '&filterValue=' + encodeURIComponent(String(filterValue)) : '') +\n (startKey ? '&startKey=' + encodeURIComponent(String(startKey)) : '') +\n (startDocumentId ? '&startDocumentId=' + encodeURIComponent(String(startDocumentId)) : '') +\n (limit ? '&limit=' + encodeURIComponent(String(limit)) : '') +\n (sortDirection ? '&sortDirection=' + encodeURIComponent(String(sortDirection)) : '')\n let headers = await this.headers\n return XHR.sendCommand('GET', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => new PaginatedListPatient(doc.body as JSON))\n .catch((err) => this.handleError(err))\n }\n\n /**\n *\n * @summary Provides a paginated list of patients with duplicate name for an hecparty\n * @param hcPartyId Healthcare party id\n * @param startKey The start key for pagination, depends on the filters used\n * @param startDocumentId A patient document ID\n * @param limit Number of rows\n */\n async findDuplicatesByName(hcPartyId: string, startKey?: string, startDocumentId?: string, limit?: number): Promise<PaginatedListPatient> {\n let _body = null\n\n const _url =\n this.host +\n `/patient/duplicates/name` +\n '?ts=' +\n new Date().getTime() +\n (hcPartyId ? '&hcPartyId=' + encodeURIComponent(String(hcPartyId)) : '') +\n (startKey ? '&startKey=' + encodeURIComponent(String(startKey)) : '') +\n (startDocumentId ? '&startDocumentId=' + encodeURIComponent(String(startDocumentId)) : '') +\n (limit ? '&limit=' + encodeURIComponent(String(limit)) : '')\n let headers = await this.headers\n return XHR.sendCommand('POST', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => new PaginatedListPatient(doc.body as JSON))\n .catch((err) => this.handleError(err))\n }\n\n /**\n *\n * @summary Provides a paginated list of patients with duplicate ssin for an hecparty\n * @param hcPartyId Healthcare party id\n * @param startKey The start key for pagination, depends on the filters used\n * @param startDocumentId A patient document ID\n * @param limit Number of rows\n */\n async findDuplicatesBySsin(hcPartyId: string, startKey?: string, startDocumentId?: string, limit?: number): Promise<PaginatedListPatient> {\n let _body = null\n\n const _url =\n this.host +\n `/patient/duplicates/ssin` +\n '?ts=' +\n new Date().getTime() +\n (hcPartyId ? '&hcPartyId=' + encodeURIComponent(String(hcPartyId)) : '') +\n (startKey ? '&startKey=' + encodeURIComponent(String(startKey)) : '') +\n (startDocumentId ? '&startDocumentId=' + encodeURIComponent(String(startDocumentId)) : '') +\n (limit ? '&limit=' + encodeURIComponent(String(limit)) : '')\n let headers = await this.headers\n return XHR.sendCommand('POST', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => new PaginatedListPatient(doc.body as JSON))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * Returns a list of patients\n * @summary Filter patients for the current user (HcParty)\n * @param firstName The first name\n * @param lastName The last name\n * @param dateOfBirth The date of birth\n */\n async fuzzySearch(firstName?: string, lastName?: string, dateOfBirth?: number): Promise<Array<Patient>> {\n let _body = null\n\n const _url =\n this.host +\n `/patient/fuzzy` +\n '?ts=' +\n new Date().getTime() +\n (firstName ? '&firstName=' + encodeURIComponent(String(firstName)) : '') +\n (lastName ? '&lastName=' + encodeURIComponent(String(lastName)) : '') +\n (dateOfBirth ? '&dateOfBirth=' + encodeURIComponent(String(dateOfBirth)) : '')\n let headers = await this.headers\n return XHR.sendCommand('GET', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => (doc.body as Array<JSON>).map((it) => new Patient(it)))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * It gets patient administrative data.\n * @summary Get patient\n * @param patientId\n */\n async getPatient(patientId: string): Promise<Patient> {\n let _body = null\n\n const _url = this.host + `/patient/${encodeURIComponent(String(patientId))}` + '?ts=' + new Date().getTime()\n let headers = await this.headers\n return XHR.sendCommand('GET', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => new Patient(doc.body as JSON))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * (key, value) of the map is as follows: (ID of the owner of the encrypted AES key, encrypted AES keys)\n * @summary Get the HcParty encrypted AES keys indexed by owner.\n * @param patientId\n */\n async getPatientAesExchangeKeysForDelegate(\n patientId: string\n ): Promise<{ [delegatorId: string]: { [delegatorPubKeyFingerprint: string]: { [delegatePubKeyFingerprint: string]: string } } }> {\n let _body = null\n\n const _url = this.host + `/patient/${encodeURIComponent(String(patientId))}/aesExchangeKeys` + '?ts=' + new Date().getTime()\n let headers = await this.headers\n return XHR.sendCommand('GET', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => JSON.parse(JSON.stringify(doc.body)))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * It gets patient administrative data based on the identifier (root & extension) parameters.\n * @summary Get patient by identifier\n * @param hcPartyId\n * @param id\n * @param system\n */\n async getPatientByHealthcarepartyAndIdentifier(hcPartyId: string, id: string, system?: string): Promise<Patient> {\n let _body = null\n\n const _url =\n this.host +\n `/patient/${encodeURIComponent(String(hcPartyId))}/${encodeURIComponent(String(id))}` +\n '?ts=' +\n new Date().getTime() +\n (system ? '&system=' + encodeURIComponent(String(system)) : '')\n let headers = await this.headers\n return XHR.sendCommand('GET', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => new Patient(doc.body as JSON))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * This endpoint is used to recover all keys that have already been created and that can be used to share information with this patient. It returns a map with the following structure: ID of the owner of the encrypted AES key -> encrypted AES key. The returned encrypted AES keys will have to be decrypted using the patient's private key. { \\\"hcparty 1 delegator ID\\\": \\\"AES hcparty key (encrypted using patient public RSA key)\\\" \\\"hcparty 2 delegator ID\\\": \\\"other AES hcparty key (encrypted using patient public RSA key)\\\" }\n * @summary Get the patient (identified by patientId) hcparty keys. Those keys are AES keys (encrypted) used to share information between HCPs and a patient.\n * @param patientId The patient Id for which information is shared\n */\n async getPatientHcPartyKeysForDelegate(patientId: string): Promise<{ [key: string]: string }> {\n let _body = null\n\n const _url = this.host + `/patient/${encodeURIComponent(String(patientId))}/keys` + '?ts=' + new Date().getTime()\n let headers = await this.headers\n return XHR.sendCommand('GET', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => JSON.parse(JSON.stringify(doc.body)))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * It gets patient administrative data.\n * @summary Get patients by id\n * @param body\n */\n async getPatients(body?: ListOfIds): Promise<Array<Patient>> {\n const _url = this.host + `/patient/byIds` + '?ts=' + new Date().getTime()\n let headers = await this.headers\n headers = headers.filter((h) => h.header !== 'Content-Type').concat(new XHR.Header('Content-Type', 'application/json'))\n return XHR.sendCommand('POST', _url, headers, body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => (doc.body as Array<JSON>).map((it) => new Patient(it)))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * Returns a list of deleted patients, within the specified time period, if any.\n * @summary Find deleted patients\n * @param startDate Filter deletions after this date (unix epoch), included\n * @param endDate Filter deletions before this date (unix epoch), included\n * @param startKey the startKey provided by the previous page or undefined for the first page.\n * @param desc Descending\n * @param startDocumentId A patient document ID\n * @param limit Number of rows\n */\n async listDeletedPatients(\n startDate?: number,\n endDate?: number,\n desc?: boolean,\n startKey?: string,\n startDocumentId?: string,\n limit?: number\n ): Promise<PaginatedListPatient> {\n const _url =\n this.host +\n `/patient/deleted/byDate` +\n '?ts=' +\n new Date().getTime() +\n (startDate ? '&startDate=' + encodeURIComponent(startDate) : '') +\n (endDate ? '&endDate=' + encodeURIComponent(endDate) : '') +\n (desc ? '&desc=' + encodeURIComponent(desc) : '') +\n (startKey ? '&startKey=' + encodeURIComponent(startKey) : '') +\n (startDocumentId ? '&startDocumentId=' + encodeURIComponent(startDocumentId) : '') +\n (limit ? '&limit=' + encodeURIComponent(limit) : '')\n let headers = await this.headers\n return XHR.sendCommand('GET', _url, headers, null, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => new PaginatedListPatient(doc.body as JSON))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * Returns a list of deleted patients, by name and/or firstname prefix, if any.\n * @summary Find deleted patients\n * @param firstName First name prefix\n * @param lastName Last name prefix\n */\n async listDeletedPatientsByName(firstName?: string, lastName?: string): Promise<Array<Patient>> {\n let _body = null\n\n const _url =\n this.host +\n `/patient/deleted/by_name` +\n '?ts=' +\n new Date().getTime() +\n (firstName ? '&firstName=' + encodeURIComponent(String(firstName)) : '') +\n (lastName ? '&lastName=' + encodeURIComponent(String(lastName)) : '')\n let headers = await this.headers\n return XHR.sendCommand('GET', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => (doc.body as Array<JSON>).map((it) => new Patient(it)))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * Returns a list of patients that have been merged after the provided date\n * @summary List patients that have been merged towards another patient\n * @param date\n */\n async listOfMergesAfter(date: number): Promise<Array<Patient>> {\n let _body = null\n\n const _url = this.host + `/patient/merges/${encodeURIComponent(String(date))}` + '?ts=' + new Date().getTime()\n let headers = await this.headers\n return XHR.sendCommand('GET', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => (doc.body as Array<JSON>).map((it) => new Patient(it)))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * Returns a list of patients that have been modified after the provided date\n * @summary List patients that have been modified after the provided date\n * @param date\n * @param startKey The start key for pagination the date of the first element of the new page\n * @param startDocumentId A patient document ID\n * @param limit Number of rows\n */\n async listOfPatientsModifiedAfter(date: number, startKey?: number, startDocumentId?: string, limit?: number): Promise<PaginatedListPatient> {\n let _body = null\n\n const _url =\n this.host +\n `/patient/modifiedAfter/${encodeURIComponent(String(date))}` +\n '?ts=' +\n new Date().getTime() +\n (startKey ? '&startKey=' + encodeURIComponent(String(startKey)) : '') +\n (startDocumentId ? '&startDocumentId=' + encodeURIComponent(String(startDocumentId)) : '') +\n (limit ? '&limit=' + encodeURIComponent(String(limit)) : '')\n let headers = await this.headers\n return XHR.sendCommand('GET', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => new PaginatedListPatient(doc.body as JSON))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * @deprecated This method is not intuitive and will be removed in a future version\n * Currently there is no direct replacement that can do everything this method does.\n * If you need all patients unsorted or sorted by ssin/date of birth use `PatientByHcPartyFilter`/`PatientByHcPartyDateOfBirthFilter`\n * with {@link matchPatientsBy} to get the ids of all the patients shared directly with an HCP (ignoring hierarchies).\n * Note that on databases with many patients (>50k) the matches request could take various seconds as it is not\n * paginated.\n * If you want to use pagination or need to sort by name instead you can use the {@link listPatientsSortedByName}.\n * Usage of PatientByHcPartyNameFilter or PatientByHcPartyNameContainsFuzzyFilter as a replacement of this method is\n * discouraged as the sorting done by those filter is unintuitive.\n * Contact us if your use case is not covered by the suggested alternatives.\n *\n * This method returns all the patients (with pagination) that are shared directly with the parent of {@link hcPartyId},\n * or if undefined the current user's parent. Note that this doesn't allow to get patients that are shared only with\n * the current user and not its parent.\n */\n async listPatients(\n hcPartyId?: string,\n sortField?: string,\n startKey?: string,\n startDocumentId?: string,\n limit?: number,\n sortDirection?: string\n ): Promise<PaginatedListPatient> {\n let _body = null\n\n const _url =\n this.host +\n `/patient` +\n '?ts=' +\n new Date().getTime() +\n (hcPartyId ? '&hcPartyId=' + encodeURIComponent(String(hcPartyId)) : '') +\n (sortField ? '&sortField=' + encodeURIComponent(String(sortField)) : '') +\n (startKey ? '&startKey=' + encodeURIComponent(String(startKey)) : '') +\n (startDocumentId ? '&startDocumentId=' + encodeURIComponent(String(startDocumentId)) : '') +\n (limit ? '&limit=' + encodeURIComponent(String(limit)) : '') +\n (sortDirection ? '&sortDirection=' + encodeURIComponent(String(sortDirection)) : '')\n let headers = await this.headers\n return XHR.sendCommand('GET', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => new PaginatedListPatient(doc.body as JSON))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * Get all patients shared directly with the provided hcparty (ignoring hierarchies) sorted by lastName, firstName.\n */\n async listPatientsSortedByName(hcPartyId?: string, startKey?: string, startDocumentId?: string, limit?: number): Promise<PaginatedListPatient> {\n let _body = null\n\n const _url =\n this.host +\n `/patient/byHcPartyId` +\n '?ts=' +\n new Date().getTime() +\n (hcPartyId ? '&hcPartyId=' + encodeURIComponent(String(hcPartyId)) : '') +\n (startKey ? '&startKey=' + encodeURIComponent(String(startKey)) : '') +\n (startDocumentId ? '&startDocumentId=' + encodeURIComponent(String(startDocumentId)) : '') +\n (limit ? '&limit=' + encodeURIComponent(String(limit)) : '')\n let headers = await this.headers\n return XHR.sendCommand('GET', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => new PaginatedListPatient(doc.body as JSON))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * Returns a list of patients along with next start keys and Document ID. If the nextStartKey is Null it means that this is the last page.\n * @summary List patients for a specific HcParty or for the current HcParty\n * @param hcPartyId\n * @param sortField Optional value for sorting results by a given field (&#x27;name&#x27;, &#x27;ssin&#x27;, &#x27;dateOfBirth&#x27;). Specifying this deactivates filtering\n * @param startKey The start key for pagination: a JSON representation of an array containing all the necessary components to form the Complex Key&#x27;s startKey\n * @param startDocumentId A patient document ID\n * @param limit Number of rows\n * @param sortDirection Optional value for providing a sorting direction (&#x27;asc&#x27;, &#x27;desc&#x27;). Set to &#x27;asc&#x27; by default.\n */\n async listPatientsByHcParty(\n hcPartyId: string,\n sortField?: string,\n startKey?: string,\n startDocumentId?: string,\n limit?: number,\n sortDirection?: string\n ): Promise<PaginatedListPatient> {\n let _body = null\n\n const _url =\n this.host +\n `/patient/hcParty/${encodeURIComponent(String(hcPartyId))}` +\n '?ts=' +\n new Date().getTime() +\n (sortField ? '&sortField=' + encodeURIComponent(String(sortField)) : '') +\n (startKey ? '&startKey=' + encodeURIComponent(String(startKey)) : '') +\n (startDocumentId ? '&startDocumentId=' + encodeURIComponent(String(startDocumentId)) : '') +\n (limit ? '&limit=' + encodeURIComponent(String(limit)) : '') +\n (sortDirection ? '&sortDirection=' + encodeURIComponent(String(sortDirection)) : '')\n let headers = await this.headers\n return XHR.sendCommand('GET', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => new PaginatedListPatient(doc.body as JSON))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * Returns a list of patients along with next start keys and Document ID. If the nextStartKey is Null it means that this is the last page.\n * @summary List patients by pages for a specific HcParty\n * @param hcPartyId Healthcare party id\n * @param startKey The page first id\n * @param startDocumentId A patient document ID\n * @param limit Page size\n */\n async listPatientsIds(hcPartyId: string, startKey?: string, startDocumentId?: string, limit?: number): Promise<PaginatedListString> {\n let _body = null\n\n const _url =\n this.host +\n `/patient/byHcPartyId` +\n '?ts=' +\n new Date().getTime() +\n (hcPartyId ? '&hcPartyId=' + encodeURIComponent(String(hcPartyId)) : '') +\n (startKey ? '&startKey=' + encodeURIComponent(String(startKey)) : '') +\n (startDocumentId ? '&startDocumentId=' + encodeURIComponent(String(startDocumentId)) : '') +\n (limit ? '&limit=' + encodeURIComponent(String(limit)) : '')\n let headers = await this.headers\n return XHR.sendCommand('GET', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => new PaginatedListString(doc.body as JSON))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * Returns a list of patients along with next start keys and Document ID. If the nextStartKey is Null it means that this is the last page.\n * @summary List patients of a specific HcParty or of the current HcParty\n * @param hcPartyId\n * @param sortField Optional value for sorting results by a given field (&#x27;name&#x27;, &#x27;ssin&#x27;, &#x27;dateOfBirth&#x27;). Specifying this deactivates filtering\n * @param startKey The start key for pagination: a JSON representation of an array containing all the necessary components to form the Complex Key&#x27;s startKey\n * @param startDocumentId A patient document ID\n * @param limit Number of rows\n * @param sortDirection Optional value for providing a sorting direction (&#x27;asc&#x27;, &#x27;desc&#x27;). Set to &#x27;asc&#x27; by default.\n */\n async listPatientsOfHcParty(\n hcPartyId: string,\n sortField?: string,\n startKey?: string,\n startDocumentId?: string,\n limit?: number,\n sortDirection?: string\n ): Promise<PaginatedListPatient> {\n let _body = null\n\n const _url =\n this.host +\n `/patient/ofHcParty/${encodeURIComponent(String(hcPartyId))}` +\n '?ts=' +\n new Date().getTime() +\n (sortField ? '&sortField=' + encodeURIComponent(String(sortField)) : '') +\n (startKey ? '&startKey=' + encodeURIComponent(String(startKey)) : '') +\n (startDocumentId ? '&startDocumentId=' + encodeURIComponent(String(startDocumentId)) : '') +\n (limit ? '&limit=' + encodeURIComponent(String(limit)) : '') +\n (sortDirection ? '&sortDirection=' + encodeURIComponent(String(sortDirection)) : '')\n let headers = await this.headers\n return XHR.sendCommand('GET', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => new PaginatedListPatient(doc.body as JSON))\n .catch((err) => this.handleError(err))\n }\n\n /**\n *\n * @summary Get ids of patients matching the provided filter for the current user (HcParty)\n * @param body\n * @param collectTiming if true, include server-side filter timing information in the response\n */\n matchPatientsBy(body?: AbstractFilterPatient, collectTiming?: false): Promise<Array<string>>\n matchPatientsBy(body?: AbstractFilterPatient, collectTiming?: true): Promise<Array<string> & TimingInfo>\n async matchPatientsBy(body?: AbstractFilterPatient, collectTiming: boolean = false): Promise<Array<string>> {\n const _url = this.host + `/patient/match` + '?ts=' + new Date().getTime()\n let headers = await this.headers\n headers = headers.filter((h) => h.header !== 'Content-Type').concat(new XHR.Header('Content-Type', 'application/json'))\n return XHR.sendCommand(\n 'POST',\n _url,\n headers,\n body,\n this.fetchImpl,\n undefined,\n this.authenticationProvider.getAuthService(),\n undefined,\n false,\n collectTiming ? ['x-filter-timing-*'] : []\n )\n .then((doc) =>\n Object.assign(\n (doc.body as Array<JSON>).map((it) => JSON.parse(JSON.stringify(it))),\n collectTiming ? { responseHeaders: doc.responseHeaders } : {}\n )\n )\n .catch((err) => this.handleError(err))\n }\n\n /**\n *\n * @summary Merge a series of patients into another patient\n * @param toId\n * @param fromIds\n */\n async mergeInto(toId: string, fromIds: string): Promise<Patient> {\n let _body = null\n\n const _url =\n this.host + `/patient/mergeInto/${encodeURIComponent(String(toId))}/from/${encodeURIComponent(String(fromIds))}` + '?ts=' + new Date().getTime()\n let headers = await this.headers\n return XHR.sendCommand('PUT', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => new Patient(doc.body as JSON))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * No particular return value. It's just a message.\n * @summary Modify a patient\n * @param body\n */\n async modifyPatient(body?: Patient): Promise<Patient> {\n let _body = null\n _body = body\n\n const _url = this.host + `/patient` + '?ts=' + new Date().getTime()\n let headers = await this.headers\n headers = headers.filter((h) => h.header !== 'Content-Type').concat(new XHR.Header('Content-Type', 'application/json'))\n return XHR.sendCommand('PUT', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => new Patient(doc.body as JSON))\n .catch((err) => this.handleError(err))\n }\n\n /**\n *\n * @summary Set a patient referral doctor\n * @param patientId\n * @param referralId The referal id. Accepts &#x27;none&#x27; for referral removal.\n * @param start Optional value for start of referral\n * @param end Optional value for end of referral\n */\n async modifyPatientReferral(patientId: string, referralId: string, start?: number, end?: number): Promise<Patient> {\n let _body = null\n\n const _url =\n this.host +\n `/patient/${encodeURIComponent(String(patientId))}/referral/${encodeURIComponent(String(referralId))}` +\n '?ts=' +\n new Date().getTime() +\n (start ? '&start=' + encodeURIComponent(String(start)) : '') +\n (end ? '&end=' + encodeURIComponent(String(end)) : '')\n let headers = await this.headers\n return XHR.sendCommand('PUT', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => new Patient(doc.body as JSON))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * Register a new patient into the system\n * @summary Register a patient\n * @param body\n * @param hcPartyId\n * @param groupId\n * @param token\n * @param useShortToken\n */\n async registerPatient(\n hcPartyId: string,\n groupId: string,\n token?: string,\n useShortToken?: boolean,\n body?: Patient\n ): Promise<DataOwnerRegistrationSuccess> {\n let _body = null\n _body = body\n\n const _url =\n this.host +\n `/patient/register/forHcp/${encodeURIComponent(String(hcPartyId))}/inGroup/${encodeURIComponent(String(groupId))}` +\n '?ts=' +\n new Date().getTime() +\n (token ? '&token=' + encodeURIComponent(String(token)) : '') +\n (useShortToken ? '&useShortToken=' + encodeURIComponent(String(useShortToken)) : '')\n let headers = await this.headers\n headers = headers.filter((h) => h.header !== 'Content-Type').concat(new XHR.Header('Content-Type', 'application/json'))\n return XHR.sendCommand('POST', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => new DataOwnerRegistrationSuccess(doc.body as JSON))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * Response is an array containing the ID of undeleted patient..\n * @summary undelete previously deleted patients\n * @param patientIds\n */\n async undeletePatient(patientIds: string): Promise<Array<DocIdentifier>> {\n let _body = null\n\n const _url = this.host + `/patient/undelete/${encodeURIComponent(String(patientIds))}` + '?ts=' + new Date().getTime()\n let headers = await this.headers\n return XHR.sendCommand('PUT', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => (doc.body as Array<JSON>).map((it) => new DocIdentifier(it)))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * @internal this method is for internal use only and may be changed without notice\n */\n async bulkSharePatients(request: BulkShareOrUpdateMetadataParams): Promise<EntityBulkShareResult<Patient>[]> {\n const _url = this.host + '/patient/bulkSharedMetadataUpdate' + '?ts=' + new Date().getTime()\n let headers = await this.headers\n headers = headers.filter((h) => h.header !== 'Content-Type').concat(new XHR.Header('Content-Type', 'application/json'))\n return XHR.sendCommand('PUT', _url, headers, request, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => (doc.body as Array<JSON>).map((x) => new EntityBulkShareResult<Patient>(x, Patient)))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * @internal use mergePatients from the extended api instead\n */\n async baseMergePatients(fromId: string, expectedFromRev: string, updatedInto: Patient) {\n let _body = updatedInto\n\n const _url =\n this.host +\n `/patient/mergeInto/${encodeURIComponent(String(updatedInto.id))}/from/${encodeURIComponent(String(fromId))}` +\n '?ts=' +\n new Date().getTime() +\n '&expectedFromRev=' +\n encodeURIComponent(String(expectedFromRev))\n let headers = await this.headers\n headers = headers.filter((h) => h.header !== 'Content-Type').concat(new XHR.Header('Content-Type', 'application/json'))\n return XHR.sendCommand('PUT', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => new Patient(doc.body as JSON))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * Retrieves the ids of all the patients that currently have conflicting revisions and therefore need to\n * be resolved.\n * @summary List the ids of the patients that have conflicts.\n * @return the ids of the patients with unresolved conflicts.\n */\n async getConflictingEntitiesIds(): Promise<Array<string>> {\n const _url = this.host + `/patient/conflicts` + '?ts=' + new Date().getTime()\n let headers = await this.headers\n return XHR.sendCommand('GET', _url, headers, null, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => doc.body as Array<string>)\n .catch((err) => this.handleError(err))\n }\n\n /**\n * Retrieves all the conflicting revisions of the patient with the given id (the current revision is not\n * included). The returned entities are still encrypted.\n * @summary Get the conflicting revisions of a patient.\n * @param entityId the id of the patient to retrieve the conflicts for.\n * @return the conflicting revisions of the patient.\n */\n async getConflictsForEntity(entityId: string): Promise<Array<Patient>> {\n const _url = this.host + `/patient/conflicts/of?entityId=${encodeURIComponent(String(entityId))}` + '&ts=' + new Date().getTime()\n let headers = await this.headers\n return XHR.sendCommand('GET', _url, headers, null, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => (doc.body as Array<JSON>).map((it) => new Patient(it)))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * Resolves a conflict by declaring which revision of the patient should be kept as winner and which\n * conflicting revisions should be purged. The provided document must already be encrypted.\n * @summary Declare the winning revision of a conflicting patient.\n * @param body the {@link ConflictResolutionRequest} carrying the winning revision and the conflicts to purge.\n * @return the {@link ConflictResolutionResult} with the saved winner and the conflicts that are still unresolved.\n */\n async declareConflictWinner(body: ConflictResolutionRequest<Patient>): Promise<ConflictResolutionResult<Patient>> {\n const _url = this.host + `/patient/conflicts/winner` + '?ts=' + new Date().getTime()\n let headers = await this.headers\n headers = headers.filter((h) => h.header !== 'Content-Type').concat(new XHR.Header('Content-Type', 'application/json'))\n return XHR.sendCommand('POST', _url, headers, body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => new ConflictResolutionResult<Patient>(doc.body, (x) => new Patient(x)))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * Like {@link getConflictingEntitiesIds} but targets the entities of the group with the given id.\n * @summary List the ids of the patients that have conflicts, in the given group.\n * @param groupId the id of the group to look into.\n * @return the ids of the patients with unresolved conflicts in the group.\n */\n async getConflictingEntitiesIdsInGroup(groupId: string): Promise<Array<string>> {\n const _url = this.host + `/patient/inGroup/${encodeURIComponent(String(groupId))}/conflicts` + '?ts=' + new Date().getTime()\n let headers = await this.headers\n return XHR.sendCommand('GET', _url, headers, null, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => doc.body as Array<string>)\n .catch((err) => this.handleError(err))\n }\n\n /**\n * Like {@link getConflictsForEntity} but targets the entity of the group with the given id.\n * @summary Get the conflicting revisions of a patient, in the given group.\n * @param groupId the id of the group the patient belongs to.\n * @param entityId the id of the patient to retrieve the conflicts for.\n * @return the conflicting revisions of the patient.\n */\n async getConflictsForEntityInGroup(groupId: string, entityId: string): Promise<Array<Patient>> {\n const _url =\n this.host +\n `/patient/inGroup/${encodeURIComponent(String(groupId))}/conflicts/of?entityId=${encodeURIComponent(String(entityId))}` +\n '&ts=' +\n new Date().getTime()\n let headers = await this.headers\n return XHR.sendCommand('GET', _url, headers, null, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => (doc.body as Array<JSON>).map((it) => new Patient(it)))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * Like {@link declareConflictWinner} but targets the entity of the group with the given id.\n * @summary Declare the winning revision of a conflicting patient, in the given group.\n * @param groupId the id of the group the patient belongs to.\n * @param body the {@link ConflictResolutionRequest} carrying the winning revision and the conflicts to purge.\n * @return the {@link ConflictResolutionResult} with the saved winner and the conflicts that are still unresolved.\n */\n async declareConflictWinnerInGroup(groupId: string, body: ConflictResolutionRequest<Patient>): Promise<ConflictResolutionResult<Patient>> {\n const _url = this.host + `/patient/inGroup/${encodeURIComponent(String(groupId))}/conflicts/winner` + '?ts=' + new Date().getTime()\n let headers = await this.headers\n headers = headers.filter((h) => h.header !== 'Content-Type').concat(new XHR.Header('Content-Type', 'application/json'))\n return XHR.sendCommand('POST', _url, headers, body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => new ConflictResolutionResult<Patient>(doc.body, (x) => new Patient(x)))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * Automatically resolves the conflicting revisions of the patients with the given ids, according to the provided\n * {@link ConflictResolutionStrategy}.\n * @summary Automatically solve the conflicts of the patients with the given ids.\n * @param entityIds the ids of the patients to solve the conflicts for.\n * @param strategy the {@link ConflictResolutionStrategy} to use to resolve the conflicts. Defaults to `FullMergeability`.\n * @return the {@link MergeResult} of the conflict resolution for each requested entity.\n */\n async autoSolveConflicts(\n entityIds: Array<string>,\n strategy: ConflictResolutionStrategy = ConflictResolutionStrategy.FullMergeability\n ): Promise<Array<MergeResult>> {\n const _url = this.host + `/patient/conflicts/solve?strategy=${encodeURIComponent(String(strategy))}` + '&ts=' + new Date().getTime()\n let headers = await this.headers\n headers = headers.filter((h) => h.header !== 'Content-Type').concat(new XHR.Header('Content-Type', 'application/json'))\n return XHR.sendCommand('POST', _url, headers, entityIds, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => (doc.body as Array<JSON>).map((it) => new MergeResult(it)))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * Like {@link autoSolveConflicts} but targets the entities of the group with the given id.\n * @summary Automatically solve the conflicts of the patients with the given ids, in the given group.\n * @param groupId the id of the group to look into.\n * @param entityIds the ids of the patients to solve the conflicts for.\n * @param strategy the {@link ConflictResolutionStrategy} to use to resolve the conflicts. Defaults to `FullMergeability`.\n * @return the {@link MergeResult} of the conflict resolution for each requested entity.\n */\n async autoSolveConflictsInGroup(\n groupId: string,\n entityIds: Array<string>,\n strategy: ConflictResolutionStrategy = ConflictResolutionStrategy.FullMergeability\n ): Promise<Array<MergeResult>> {\n const _url =\n this.host +\n `/patient/inGroup/${encodeURIComponent(String(groupId))}/conflicts/solve?strategy=${encodeURIComponent(String(strategy))}` +\n '&ts=' +\n new Date().getTime()\n let headers = await this.headers\n headers = headers.filter((h) => h.header !== 'Content-Type').concat(new XHR.Header('Content-Type', 'application/json'))\n return XHR.sendCommand('POST', _url, headers, entityIds, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => (doc.body as Array<JSON>).map((it) => new MergeResult(it)))\n .catch((err) => this.handleError(err))\n }\n}\n"]}
@@ -17,6 +17,8 @@ import { ListOfIds } from '../model/ListOfIds';
17
17
  import { PaginatedListPlace } from '../model/PaginatedListPlace';
18
18
  import { ConflictResolutionRequest } from '../model/ConflictResolutionRequest';
19
19
  import { ConflictResolutionResult } from '../model/ConflictResolutionResult';
20
+ import { ConflictResolutionStrategy } from '../model/ConflictResolutionStrategy';
21
+ import { MergeResult } from '../model/MergeResult';
20
22
  export declare class IccPlaceApi {
21
23
  host: string;
22
24
  headers: Array<XHR.Header>;
@@ -85,4 +87,22 @@ export declare class IccPlaceApi {
85
87
  * @return the {@link ConflictResolutionResult} with the saved winner and the conflicts that are still unresolved.
86
88
  */
87
89
  declareConflictWinner(body: ConflictResolutionRequest<Place>): Promise<ConflictResolutionResult<Place>>;
90
+ /**
91
+ * Automatically resolves the conflicting revisions of the places with the given ids, according to the provided
92
+ * {@link ConflictResolutionStrategy}.
93
+ * @summary Automatically solve the conflicts of the places with the given ids.
94
+ * @param entityIds the ids of the places to solve the conflicts for.
95
+ * @param strategy the {@link ConflictResolutionStrategy} to use to resolve the conflicts. Defaults to `FullMergeability`.
96
+ * @return the {@link MergeResult} of the conflict resolution for each requested entity.
97
+ */
98
+ autoSolveConflicts(entityIds: Array<string>, strategy?: ConflictResolutionStrategy): Promise<Array<MergeResult>>;
99
+ /**
100
+ * Like {@link autoSolveConflicts} but targets the entities of the group with the given id.
101
+ * @summary Automatically solve the conflicts of the places with the given ids, in the given group.
102
+ * @param groupId the id of the group to look into.
103
+ * @param entityIds the ids of the places to solve the conflicts for.
104
+ * @param strategy the {@link ConflictResolutionStrategy} to use to resolve the conflicts. Defaults to `FullMergeability`.
105
+ * @return the {@link MergeResult} of the conflict resolution for each requested entity.
106
+ */
107
+ autoSolveConflictsInGroup(groupId: string, entityIds: Array<string>, strategy?: ConflictResolutionStrategy): Promise<Array<MergeResult>>;
88
108
  }
@@ -28,6 +28,8 @@ const AuthenticationProvider_1 = require("../../icc-x-api/auth/AuthenticationPro
28
28
  const IccRestApiPath_1 = require("./IccRestApiPath");
29
29
  const PaginatedListPlace_1 = require("../model/PaginatedListPlace");
30
30
  const ConflictResolutionResult_1 = require("../model/ConflictResolutionResult");
31
+ const ConflictResolutionStrategy_1 = require("../model/ConflictResolutionStrategy");
32
+ const MergeResult_1 = require("../model/MergeResult");
31
33
  class IccPlaceApi {
32
34
  constructor(host, headers, authenticationProvider, fetchImpl) {
33
35
  this.host = (0, IccRestApiPath_1.iccRestApiPath)(host);
@@ -178,6 +180,45 @@ class IccPlaceApi {
178
180
  .catch((err) => this.handleError(err));
179
181
  });
180
182
  }
183
+ /**
184
+ * Automatically resolves the conflicting revisions of the places with the given ids, according to the provided
185
+ * {@link ConflictResolutionStrategy}.
186
+ * @summary Automatically solve the conflicts of the places with the given ids.
187
+ * @param entityIds the ids of the places to solve the conflicts for.
188
+ * @param strategy the {@link ConflictResolutionStrategy} to use to resolve the conflicts. Defaults to `FullMergeability`.
189
+ * @return the {@link MergeResult} of the conflict resolution for each requested entity.
190
+ */
191
+ autoSolveConflicts(entityIds_1) {
192
+ return __awaiter(this, arguments, void 0, function* (entityIds, strategy = ConflictResolutionStrategy_1.ConflictResolutionStrategy.FullMergeability) {
193
+ const _url = this.host + `/place/conflicts/solve?strategy=${encodeURIComponent(String(strategy))}` + '&ts=' + new Date().getTime();
194
+ let headers = yield this.headers;
195
+ headers = headers.filter((h) => h.header !== 'Content-Type').concat(new XHR_1.XHR.Header('Content-Type', 'application/json'));
196
+ return XHR_1.XHR.sendCommand('POST', _url, headers, entityIds, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())
197
+ .then((doc) => doc.body.map((it) => new MergeResult_1.MergeResult(it)))
198
+ .catch((err) => this.handleError(err));
199
+ });
200
+ }
201
+ /**
202
+ * Like {@link autoSolveConflicts} but targets the entities of the group with the given id.
203
+ * @summary Automatically solve the conflicts of the places with the given ids, in the given group.
204
+ * @param groupId the id of the group to look into.
205
+ * @param entityIds the ids of the places to solve the conflicts for.
206
+ * @param strategy the {@link ConflictResolutionStrategy} to use to resolve the conflicts. Defaults to `FullMergeability`.
207
+ * @return the {@link MergeResult} of the conflict resolution for each requested entity.
208
+ */
209
+ autoSolveConflictsInGroup(groupId_1, entityIds_1) {
210
+ return __awaiter(this, arguments, void 0, function* (groupId, entityIds, strategy = ConflictResolutionStrategy_1.ConflictResolutionStrategy.FullMergeability) {
211
+ const _url = this.host +
212
+ `/place/inGroup/${encodeURIComponent(String(groupId))}/conflicts/solve?strategy=${encodeURIComponent(String(strategy))}` +
213
+ '&ts=' +
214
+ new Date().getTime();
215
+ let headers = yield this.headers;
216
+ headers = headers.filter((h) => h.header !== 'Content-Type').concat(new XHR_1.XHR.Header('Content-Type', 'application/json'));
217
+ return XHR_1.XHR.sendCommand('POST', _url, headers, entityIds, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())
218
+ .then((doc) => doc.body.map((it) => new MergeResult_1.MergeResult(it)))
219
+ .catch((err) => this.handleError(err));
220
+ });
221
+ }
181
222
  }
182
223
  exports.IccPlaceApi = IccPlaceApi;
183
224
  //# sourceMappingURL=IccPlaceApi.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"IccPlaceApi.js","sourceRoot":"","sources":["../../../icc-api/api/IccPlaceApi.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA;;;;;;;;;;GAUG;AACH,+BAA2B;AAC3B,0DAAsD;AACtD,0CAAsC;AACtC,wFAA8G;AAC9G,qDAAiD;AAEjD,oEAAgE;AAEhE,gFAA4E;AAE5E,MAAa,WAAW;IAMtB,YACE,IAAY,EACZ,OAAY,EACZ,sBAA+C,EAC/C,SAAyE;QAEzE,IAAI,CAAC,IAAI,GAAG,IAAA,+BAAc,EAAC,IAAI,CAAC,CAAA;QAChC,IAAI,CAAC,OAAO,GAAG,MAAM,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,IAAI,SAAG,CAAC,MAAM,CAAC,CAAC,EAAE,OAAO,CAAC,CAAC,CAAC,CAAC,CAAC,CAAA;QAC7E,IAAI,CAAC,sBAAsB,GAAG,CAAC,CAAC,sBAAsB,CAAC,CAAC,CAAC,sBAAsB,CAAC,CAAC,CAAC,IAAI,iDAAwB,EAAE,CAAA;QAChH,IAAI,CAAC,SAAS,GAAG,SAAS,CAAA;IAC5B,CAAC;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kBAAkB,CAAC,CAAC,CAAA;YACvH,OAAO,SAAG,CAAC,WAAW,CAAC,MAAM,EAAE,IAAI,EAAE,OAAO,EAAE,IAAI,EAAE,IAAI,CAAC,SAAS,EAAE,SAAS,EAAE,IAAI,CAAC,sBAAsB,CAAC,cAAc,EAAE,CAAC;iBACzH,IAAI,CAAC,CAAC,GAAG,EAAE,EAAE,CAAC,IAAI,mDAAwB,CAAQ,GAAG,CAAC,IAAI,EAAE,CAAC,CAAC,EAAE,EAAE,CAAC,IAAI,aAAK,CAAC,CAAC,CAAC,CAAC,CAAC;iBACjF,KAAK,CAAC,CAAC,GAAG,EAAE,EAAE,CAAC,IAAI,CAAC,WAAW,CAAC,GAAG,CAAC,CAAC,CAAA;QAC1C,CAAC;KAAA;CACF;AAnKD,kCAmKC","sourcesContent":["/**\n * iCure Data Stack API Documentation\n * The iCure Data Stack Application API is the native interface to iCure. This version is obsolete, please use v2.\n *\n * OpenAPI spec version: v1\n *\n *\n * NOTE: This class is auto generated by the swagger code generator program.\n * https://github.com/swagger-api/swagger-codegen.git\n * Do not edit the class manually.\n */\nimport { XHR } from './XHR'\nimport { DocIdentifier } from '../model/DocIdentifier'\nimport { Place } from '../model/Place'\nimport { AuthenticationProvider, NoAuthenticationProvider } from '../../icc-x-api/auth/AuthenticationProvider'\nimport { iccRestApiPath } from './IccRestApiPath'\nimport { ListOfIds } from '../model/ListOfIds'\nimport { PaginatedListPlace } from '../model/PaginatedListPlace'\nimport { ConflictResolutionRequest } from '../model/ConflictResolutionRequest'\nimport { ConflictResolutionResult } from '../model/ConflictResolutionResult'\n\nexport class IccPlaceApi {\n host: string\n headers: Array<XHR.Header>\n authenticationProvider: AuthenticationProvider\n fetchImpl?: (input: RequestInfo, init?: RequestInit) => Promise<Response>\n\n constructor(\n host: string,\n headers: any,\n authenticationProvider?: AuthenticationProvider,\n fetchImpl?: (input: RequestInfo, init?: RequestInit) => Promise<Response>\n ) {\n this.host = iccRestApiPath(host)\n this.headers = Object.keys(headers).map((k) => new XHR.Header(k, headers[k]))\n this.authenticationProvider = !!authenticationProvider ? authenticationProvider : new NoAuthenticationProvider()\n this.fetchImpl = fetchImpl\n }\n\n setHeaders(h: Array<XHR.Header>) {\n this.headers = h\n }\n\n handleError(e: XHR.XHRError): never {\n throw e\n }\n\n /**\n *\n * @summary Creates a place\n * @param body\n */\n async createPlace(body?: Place): Promise<Place> {\n const _url = this.host + `/place` + '?ts=' + new Date().getTime()\n let headers = this.headers\n headers = headers.filter((h) => h.header !== 'Content-Type').concat(new XHR.Header('Content-Type', 'application/json'))\n return XHR.sendCommand('POST', _url, headers, body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => new Place(doc.body as JSON))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * @summary Deletes a batch of places.\n *\n * @param placeIds a ListOfIds containing the ids of the places to delete.\n * @return a Promise that will resolve in an array of DocIdentifiers of the successfully deleted places.\n */\n async deletePlaces(placeIds: ListOfIds): Promise<Array<DocIdentifier>> {\n return XHR.sendCommand(\n 'POST',\n this.host + `/place/delete/batch` + '?ts=' + new Date().getTime(),\n this.headers.filter((h) => h.header !== 'Content-Type').concat(new XHR.Header('Content-Type', 'application/json')),\n placeIds,\n this.fetchImpl,\n undefined,\n this.authenticationProvider.getAuthService()\n )\n .then((doc) => (doc.body as Array<JSON>).map((it) => new DocIdentifier(it)))\n .catch((err) => this.handleError(err))\n }\n\n /**\n *\n * @summary Gets a place\n * @param placeId\n */\n async getPlace(placeId: string): Promise<Place> {\n let _body = null\n\n const _url = this.host + `/place/${encodeURIComponent(String(placeId))}` + '?ts=' + new Date().getTime()\n let headers = this.headers\n return XHR.sendCommand('GET', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => new Place(doc.body as JSON))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * @deprecated use {@link getPlacesWithPagination} instead.\n * @summary Gets all places\n */\n async getPlaces(): Promise<Array<Place>> {\n const _url = this.host + `/place?ts=${new Date().getTime()}&limit=1000000`\n const headers = this.headers\n return XHR.sendCommand('GET', _url, headers, null, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => new PaginatedListPlace(doc.body as JSON).rows ?? [])\n .catch((err) => this.handleError(err))\n }\n\n /**\n * @summary Gets all places with pagination.\n * @param startDocumentId the startDocumentId provided by the previous page or undefined for the first page.\n * @param limit the number of elements that the page should contain.\n * @return a promise that will resolve in a PaginatedListPlace.\n */\n async getPlacesWithPagination(startDocumentId?: string, limit?: number): Promise<PaginatedListPlace> {\n const _url =\n this.host +\n `/place?ts=${new Date().getTime()}` +\n (!!startDocumentId ? `&startDocumentId=${encodeURIComponent(startDocumentId)}` : '') +\n (!!limit ? `&limit=${limit}` : '')\n const headers = this.headers\n return XHR.sendCommand('GET', _url, headers, null, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => new PaginatedListPlace(doc.body as JSON))\n .catch((err) => this.handleError(err))\n }\n\n /**\n *\n * @summary Modifies an place\n * @param body\n */\n async modifyPlace(body?: Place): Promise<Place> {\n const _url = this.host + `/place` + '?ts=' + new Date().getTime()\n let headers = this.headers\n headers = headers.filter((h) => h.header !== 'Content-Type').concat(new XHR.Header('Content-Type', 'application/json'))\n return XHR.sendCommand('PUT', _url, headers, body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => new Place(doc.body as JSON))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * Retrieves the ids of all the places that currently have conflicting revisions and therefore need to\n * be resolved.\n * @summary List the ids of the places that have conflicts.\n * @return the ids of the places with unresolved conflicts.\n */\n async getConflictingEntitiesIds(): Promise<Array<string>> {\n const _url = this.host + `/place/conflicts` + '?ts=' + new Date().getTime()\n let headers = this.headers\n return XHR.sendCommand('GET', _url, headers, null, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => doc.body as Array<string>)\n .catch((err) => this.handleError(err))\n }\n\n /**\n * Retrieves all the conflicting revisions of the place with the given id (the current revision is not\n * included). The returned entities are still encrypted.\n * @summary Get the conflicting revisions of a place.\n * @param entityId the id of the place to retrieve the conflicts for.\n * @return the conflicting revisions of the place.\n */\n async getConflictsForEntity(entityId: string): Promise<Array<Place>> {\n const _url = this.host + `/place/conflicts/of?entityId=${encodeURIComponent(String(entityId))}` + '&ts=' + new Date().getTime()\n let headers = this.headers\n return XHR.sendCommand('GET', _url, headers, null, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => (doc.body as Array<JSON>).map((it) => new Place(it)))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * Resolves a conflict by declaring which revision of the place should be kept as winner and which\n * conflicting revisions should be purged. The provided document must already be encrypted.\n * @summary Declare the winning revision of a conflicting place.\n * @param body the {@link ConflictResolutionRequest} carrying the winning revision and the conflicts to purge.\n * @return the {@link ConflictResolutionResult} with the saved winner and the conflicts that are still unresolved.\n */\n async declareConflictWinner(body: ConflictResolutionRequest<Place>): Promise<ConflictResolutionResult<Place>> {\n const _url = this.host + `/place/conflicts/winner` + '?ts=' + new Date().getTime()\n let headers = this.headers\n headers = headers.filter((h) => h.header !== 'Content-Type').concat(new XHR.Header('Content-Type', 'application/json'))\n return XHR.sendCommand('POST', _url, headers, body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => new ConflictResolutionResult<Place>(doc.body, (x) => new Place(x)))\n .catch((err) => this.handleError(err))\n }\n}\n"]}
1
+ {"version":3,"file":"IccPlaceApi.js","sourceRoot":"","sources":["../../../icc-api/api/IccPlaceApi.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA;;;;;;;;;;GAUG;AACH,+BAA2B;AAC3B,0DAAsD;AACtD,0CAAsC;AACtC,wFAA8G;AAC9G,qDAAiD;AAEjD,oEAAgE;AAEhE,gFAA4E;AAC5E,oFAAgF;AAChF,sDAAkD;AAElD,MAAa,WAAW;IAMtB,YACE,IAAY,EACZ,OAAY,EACZ,sBAA+C,EAC/C,SAAyE;QAEz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M,EAAE,IAAI,EAAE,OAAO,EAAE,SAAS,EAAE,IAAI,CAAC,SAAS,EAAE,SAAS,EAAE,IAAI,CAAC,sBAAsB,CAAC,cAAc,EAAE,CAAC;iBAC9H,IAAI,CAAC,CAAC,GAAG,EAAE,EAAE,CAAE,GAAG,CAAC,IAAoB,CAAC,GAAG,CAAC,CAAC,EAAE,EAAE,EAAE,CAAC,IAAI,yBAAW,CAAC,EAAE,CAAC,CAAC,CAAC;iBACzE,KAAK,CAAC,CAAC,GAAG,EAAE,EAAE,CAAC,IAAI,CAAC,WAAW,CAAC,GAAG,CAAC,CAAC,CAAA;QAC1C,CAAC;KAAA;CACF;AAhND,kCAgNC","sourcesContent":["/**\n * iCure Data Stack API Documentation\n * The iCure Data Stack Application API is the native interface to iCure. This version is obsolete, please use v2.\n *\n * OpenAPI spec version: v1\n *\n *\n * NOTE: This class is auto generated by the swagger code generator program.\n * https://github.com/swagger-api/swagger-codegen.git\n * Do not edit the class manually.\n */\nimport { XHR } from './XHR'\nimport { DocIdentifier } from '../model/DocIdentifier'\nimport { Place } from '../model/Place'\nimport { AuthenticationProvider, NoAuthenticationProvider } from '../../icc-x-api/auth/AuthenticationProvider'\nimport { iccRestApiPath } from './IccRestApiPath'\nimport { ListOfIds } from '../model/ListOfIds'\nimport { PaginatedListPlace } from '../model/PaginatedListPlace'\nimport { ConflictResolutionRequest } from '../model/ConflictResolutionRequest'\nimport { ConflictResolutionResult } from '../model/ConflictResolutionResult'\nimport { ConflictResolutionStrategy } from '../model/ConflictResolutionStrategy'\nimport { MergeResult } from '../model/MergeResult'\n\nexport class IccPlaceApi {\n host: string\n headers: Array<XHR.Header>\n authenticationProvider: AuthenticationProvider\n fetchImpl?: (input: RequestInfo, init?: RequestInit) => Promise<Response>\n\n constructor(\n host: string,\n headers: any,\n authenticationProvider?: AuthenticationProvider,\n fetchImpl?: (input: RequestInfo, init?: RequestInit) => Promise<Response>\n ) {\n this.host = iccRestApiPath(host)\n this.headers = Object.keys(headers).map((k) => new XHR.Header(k, headers[k]))\n this.authenticationProvider = !!authenticationProvider ? authenticationProvider : new NoAuthenticationProvider()\n this.fetchImpl = fetchImpl\n }\n\n setHeaders(h: Array<XHR.Header>) {\n this.headers = h\n }\n\n handleError(e: XHR.XHRError): never {\n throw e\n }\n\n /**\n *\n * @summary Creates a place\n * @param body\n */\n async createPlace(body?: Place): Promise<Place> {\n const _url = this.host + `/place` + '?ts=' + new Date().getTime()\n let headers = this.headers\n headers = headers.filter((h) => h.header !== 'Content-Type').concat(new XHR.Header('Content-Type', 'application/json'))\n return XHR.sendCommand('POST', _url, headers, body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => new Place(doc.body as JSON))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * @summary Deletes a batch of places.\n *\n * @param placeIds a ListOfIds containing the ids of the places to delete.\n * @return a Promise that will resolve in an array of DocIdentifiers of the successfully deleted places.\n */\n async deletePlaces(placeIds: ListOfIds): Promise<Array<DocIdentifier>> {\n return XHR.sendCommand(\n 'POST',\n this.host + `/place/delete/batch` + '?ts=' + new Date().getTime(),\n this.headers.filter((h) => h.header !== 'Content-Type').concat(new XHR.Header('Content-Type', 'application/json')),\n placeIds,\n this.fetchImpl,\n undefined,\n this.authenticationProvider.getAuthService()\n )\n .then((doc) => (doc.body as Array<JSON>).map((it) => new DocIdentifier(it)))\n .catch((err) => this.handleError(err))\n }\n\n /**\n *\n * @summary Gets a place\n * @param placeId\n */\n async getPlace(placeId: string): Promise<Place> {\n let _body = null\n\n const _url = this.host + `/place/${encodeURIComponent(String(placeId))}` + '?ts=' + new Date().getTime()\n let headers = this.headers\n return XHR.sendCommand('GET', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => new Place(doc.body as JSON))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * @deprecated use {@link getPlacesWithPagination} instead.\n * @summary Gets all places\n */\n async getPlaces(): Promise<Array<Place>> {\n const _url = this.host + `/place?ts=${new Date().getTime()}&limit=1000000`\n const headers = this.headers\n return XHR.sendCommand('GET', _url, headers, null, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => new PaginatedListPlace(doc.body as JSON).rows ?? [])\n .catch((err) => this.handleError(err))\n }\n\n /**\n * @summary Gets all places with pagination.\n * @param startDocumentId the startDocumentId provided by the previous page or undefined for the first page.\n * @param limit the number of elements that the page should contain.\n * @return a promise that will resolve in a PaginatedListPlace.\n */\n async getPlacesWithPagination(startDocumentId?: string, limit?: number): Promise<PaginatedListPlace> {\n const _url =\n this.host +\n `/place?ts=${new Date().getTime()}` +\n (!!startDocumentId ? `&startDocumentId=${encodeURIComponent(startDocumentId)}` : '') +\n (!!limit ? `&limit=${limit}` : '')\n const headers = this.headers\n return XHR.sendCommand('GET', _url, headers, null, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => new PaginatedListPlace(doc.body as JSON))\n .catch((err) => this.handleError(err))\n }\n\n /**\n *\n * @summary Modifies an place\n * @param body\n */\n async modifyPlace(body?: Place): Promise<Place> {\n const _url = this.host + `/place` + '?ts=' + new Date().getTime()\n let headers = this.headers\n headers = headers.filter((h) => h.header !== 'Content-Type').concat(new XHR.Header('Content-Type', 'application/json'))\n return XHR.sendCommand('PUT', _url, headers, body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => new Place(doc.body as JSON))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * Retrieves the ids of all the places that currently have conflicting revisions and therefore need to\n * be resolved.\n * @summary List the ids of the places that have conflicts.\n * @return the ids of the places with unresolved conflicts.\n */\n async getConflictingEntitiesIds(): Promise<Array<string>> {\n const _url = this.host + `/place/conflicts` + '?ts=' + new Date().getTime()\n let headers = this.headers\n return XHR.sendCommand('GET', _url, headers, null, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => doc.body as Array<string>)\n .catch((err) => this.handleError(err))\n }\n\n /**\n * Retrieves all the conflicting revisions of the place with the given id (the current revision is not\n * included). The returned entities are still encrypted.\n * @summary Get the conflicting revisions of a place.\n * @param entityId the id of the place to retrieve the conflicts for.\n * @return the conflicting revisions of the place.\n */\n async getConflictsForEntity(entityId: string): Promise<Array<Place>> {\n const _url = this.host + `/place/conflicts/of?entityId=${encodeURIComponent(String(entityId))}` + '&ts=' + new Date().getTime()\n let headers = this.headers\n return XHR.sendCommand('GET', _url, headers, null, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => (doc.body as Array<JSON>).map((it) => new Place(it)))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * Resolves a conflict by declaring which revision of the place should be kept as winner and which\n * conflicting revisions should be purged. The provided document must already be encrypted.\n * @summary Declare the winning revision of a conflicting place.\n * @param body the {@link ConflictResolutionRequest} carrying the winning revision and the conflicts to purge.\n * @return the {@link ConflictResolutionResult} with the saved winner and the conflicts that are still unresolved.\n */\n async declareConflictWinner(body: ConflictResolutionRequest<Place>): Promise<ConflictResolutionResult<Place>> {\n const _url = this.host + `/place/conflicts/winner` + '?ts=' + new Date().getTime()\n let headers = this.headers\n headers = headers.filter((h) => h.header !== 'Content-Type').concat(new XHR.Header('Content-Type', 'application/json'))\n return XHR.sendCommand('POST', _url, headers, body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => new ConflictResolutionResult<Place>(doc.body, (x) => new Place(x)))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * Automatically resolves the conflicting revisions of the places with the given ids, according to the provided\n * {@link ConflictResolutionStrategy}.\n * @summary Automatically solve the conflicts of the places with the given ids.\n * @param entityIds the ids of the places to solve the conflicts for.\n * @param strategy the {@link ConflictResolutionStrategy} to use to resolve the conflicts. Defaults to `FullMergeability`.\n * @return the {@link MergeResult} of the conflict resolution for each requested entity.\n */\n async autoSolveConflicts(\n entityIds: Array<string>,\n strategy: ConflictResolutionStrategy = ConflictResolutionStrategy.FullMergeability\n ): Promise<Array<MergeResult>> {\n const _url = this.host + `/place/conflicts/solve?strategy=${encodeURIComponent(String(strategy))}` + '&ts=' + new Date().getTime()\n let headers = await this.headers\n headers = headers.filter((h) => h.header !== 'Content-Type').concat(new XHR.Header('Content-Type', 'application/json'))\n return XHR.sendCommand('POST', _url, headers, entityIds, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => (doc.body as Array<JSON>).map((it) => new MergeResult(it)))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * Like {@link autoSolveConflicts} but targets the entities of the group with the given id.\n * @summary Automatically solve the conflicts of the places with the given ids, in the given group.\n * @param groupId the id of the group to look into.\n * @param entityIds the ids of the places to solve the conflicts for.\n * @param strategy the {@link ConflictResolutionStrategy} to use to resolve the conflicts. Defaults to `FullMergeability`.\n * @return the {@link MergeResult} of the conflict resolution for each requested entity.\n */\n async autoSolveConflictsInGroup(\n groupId: string,\n entityIds: Array<string>,\n strategy: ConflictResolutionStrategy = ConflictResolutionStrategy.FullMergeability\n ): Promise<Array<MergeResult>> {\n const _url =\n this.host +\n `/place/inGroup/${encodeURIComponent(String(groupId))}/conflicts/solve?strategy=${encodeURIComponent(String(strategy))}` +\n '&ts=' +\n new Date().getTime()\n let headers = await this.headers\n headers = headers.filter((h) => h.header !== 'Content-Type').concat(new XHR.Header('Content-Type', 'application/json'))\n return XHR.sendCommand('POST', _url, headers, entityIds, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => (doc.body as Array<JSON>).map((it) => new MergeResult(it)))\n .catch((err) => this.handleError(err))\n }\n}\n"]}