@icure/api 8.8.4 → 8.8.5

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 (39) hide show
  1. package/icc-api/api/IccAccesslogApi.js +3 -3
  2. package/icc-api/api/IccAccesslogApi.js.map +1 -1
  3. package/icc-api/api/IccAgendaApi.js +1 -1
  4. package/icc-api/api/IccAgendaApi.js.map +1 -1
  5. package/icc-api/api/IccCalendarItemApi.js +1 -1
  6. package/icc-api/api/IccCalendarItemApi.js.map +1 -1
  7. package/icc-api/api/IccCalendarItemTypeApi.js +1 -1
  8. package/icc-api/api/IccCalendarItemTypeApi.js.map +1 -1
  9. package/icc-api/api/IccCodeApi.js +1 -1
  10. package/icc-api/api/IccCodeApi.js.map +1 -1
  11. package/icc-api/api/IccContactApi.js +3 -3
  12. package/icc-api/api/IccContactApi.js.map +1 -1
  13. package/icc-api/api/IccDeviceApi.js +3 -3
  14. package/icc-api/api/IccDeviceApi.js.map +1 -1
  15. package/icc-api/api/IccDocumentApi.js +3 -3
  16. package/icc-api/api/IccDocumentApi.js.map +1 -1
  17. package/icc-api/api/IccFormApi.js +3 -3
  18. package/icc-api/api/IccFormApi.js.map +1 -1
  19. package/icc-api/api/IccHcpartyApi.js +3 -3
  20. package/icc-api/api/IccHcpartyApi.js.map +1 -1
  21. package/icc-api/api/IccHelementApi.js +3 -3
  22. package/icc-api/api/IccHelementApi.js.map +1 -1
  23. package/icc-api/api/IccInsuranceApi.js +3 -3
  24. package/icc-api/api/IccInsuranceApi.js.map +1 -1
  25. package/icc-api/api/IccInvoiceApi.js +3 -3
  26. package/icc-api/api/IccInvoiceApi.js.map +1 -1
  27. package/icc-api/api/IccMessageApi.js +3 -3
  28. package/icc-api/api/IccMessageApi.js.map +1 -1
  29. package/icc-api/api/IccPatientApi.js +3 -3
  30. package/icc-api/api/IccPatientApi.js.map +1 -1
  31. package/icc-api/api/IccPlaceApi.js +1 -1
  32. package/icc-api/api/IccPlaceApi.js.map +1 -1
  33. package/icc-api/api/IccReceiptApi.js +1 -1
  34. package/icc-api/api/IccReceiptApi.js.map +1 -1
  35. package/icc-api/api/IccTopicApi.js +3 -3
  36. package/icc-api/api/IccTopicApi.js.map +1 -1
  37. package/icc-api/api/IccUserApi.js +1 -1
  38. package/icc-api/api/IccUserApi.js.map +1 -1
  39. package/package.json +1 -1
@@ -1 +1 @@
1
- {"version":3,"file":"IccReceiptApi.js","sourceRoot":"","sources":["../../../icc-api/api/IccReceiptApi.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA;;;;;;;;;;GAUG;AACH,+BAA2B;AAC3B,0DAAsD;AACtD,8CAA0C;AAC1C,wFAA8G;AAC9G,qDAAiD;AAEjD,mFAA+E;AAI/E,gFAA4E;AAE5E,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;IAED,UAAU,CAAC,CAAoB;QAC7B,IAAI,CAAC,QAAQ,GAAG,CAAC,CAAA;IACnB,CAAC;IAED,WAAW,CAAC,CAAe;QACzB,MAAM,CAAC,CAAA;IACT,CAAC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AC,GAAG,EAAE,EAAE,CAAC,IAAI,CAAC,WAAW,CAAC,GAAG,CAAC,CAAC,CAAA;QAC1C,CAAC;KAAA;IAED;;;;;;OAMG;IACG,qBAAqB,CAAC,IAAwC;;YAClE,MAAM,IAAI,GAAG,IAAI,CAAC,IAAI,GAAG,2BAA2B,GAAG,MAAM,GAAG,IAAI,IAAI,EAAE,CAAC,OAAO,EAAE,CAAA;YACpF,IAAI,OAAO,GAAG,MAAM,IAAI,CAAC,OAAO,CAAA;YAChC,OAAO,GAAG,OAAO,CAAC,MAAM,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,MAAM,KAAK,cAAc,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;AAvTD,sCAuTC","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 { Receipt } from '../model/Receipt'\nimport { AuthenticationProvider, NoAuthenticationProvider } from '../../icc-x-api/auth/AuthenticationProvider'\nimport { iccRestApiPath } from './IccRestApiPath'\nimport { EntityShareOrMetadataUpdateRequest } from '../model/requests/EntityShareOrMetadataUpdateRequest'\nimport { EntityBulkShareResult } from '../model/requests/EntityBulkShareResult'\nimport { ListOfIds } from '../model/ListOfIds'\nimport { BulkShareOrUpdateMetadataParams } from '../model/requests/BulkShareOrUpdateMetadataParams'\nimport { ConflictResolutionRequest } from '../model/ConflictResolutionRequest'\nimport { ConflictResolutionResult } from '../model/ConflictResolutionResult'\n\nexport class IccReceiptApi {\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\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 receipt\n * @param body\n */\n async createReceipt(body?: Receipt): Promise<Receipt> {\n const _url = this.host + `/receipt` + '?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 Receipt(doc.body as JSON))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * @summary Deletes a batch of receipts.\n *\n * @param receiptIds a ListOfIds containing the ids of the receipts to delete.\n * @return a Promise that will resolve in an array of DocIdentifiers of the successfully deleted receipts.\n */\n async deleteReceipts(receiptIds: 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 + `/receipt/delete/batch` + '?ts=' + new Date().getTime(),\n headers,\n receiptIds,\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 receipt by id.\n *\n * @param receiptId the id of the receipt to delete.\n * @return a Promise that will resolve in the DocIdentifier of the deleted receipt.\n */\n async deleteReceipt(receiptId: string): Promise<DocIdentifier> {\n return XHR.sendCommand(\n 'DELETE',\n this.host + `/receipt/${encodeURIComponent(receiptId)}` + '?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 *\n * @summary Gets a receipt\n * @param receiptId\n */\n async getReceipt(receiptId: string): Promise<Receipt> {\n let _body = null\n\n const _url = this.host + `/receipt/${encodeURIComponent(String(receiptId))}` + '?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 Receipt(doc.body as JSON))\n .catch((err) => this.handleError(err))\n }\n\n /**\n *\n * @summary Get an attachment\n * @param receiptId\n * @param attachmentId\n * @param enckeys\n */\n async getReceiptAttachment(receiptId: string, attachmentId: string, enckeys?: null): Promise<ArrayBuffer> {\n if (enckeys) {\n throw new Error('Server-side encryption is not supported anymore.')\n }\n let _body = null\n\n const _url =\n this.host +\n `/receipt/${encodeURIComponent(String(receiptId))}/attachment/${encodeURIComponent(String(attachmentId))}` +\n '?ts=' +\n 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)\n .catch((err) => this.handleError(err))\n }\n\n /**\n *\n * @summary Gets a receipt\n * @param ref\n */\n async listByReference(ref: string): Promise<Array<Receipt>> {\n let _body = null\n\n const _url = this.host + `/receipt/byRef/${encodeURIComponent(String(ref))}` + '?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 Receipt(it)))\n .catch((err) => this.handleError(err))\n }\n\n /**\n *\n * @summary Updates a receipt\n * @param body\n */\n async modifyReceipt(body?: Receipt): Promise<Receipt> {\n let _body = null\n _body = body\n\n const _url = this.host + `/receipt` + '?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 Receipt(doc.body as JSON))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * @deprecated use setReceiptAttachmentForBlobType instead\n */\n async setReceiptAttachment(receiptId: string, receiptRev: string, blobType: string, enckeys?: null, body?: ArrayBuffer): Promise<Receipt> {\n if (enckeys) {\n throw new Error('Server-side encryption is not supported anymore.')\n }\n if (!body) {\n throw new Error('Attachment content is requred')\n }\n return this.setReceiptAttachmentForBlobType(receiptId, receiptRev, blobType, body)\n }\n\n /**\n * @summary Creates a receipt's attachment\n * @param receiptId id of a receipt\n * @param receiptRev rev of the receipt\n * @param blobType receipt blob type\n * @param body content of the attachment, already encrypted\n */\n async setReceiptAttachmentForBlobType(receiptId: string, receiptRev: string, blobType: string, body: ArrayBuffer): Promise<Receipt> {\n if (!receiptRev) throw new Error('Receipt rev is required')\n\n let _body = body\n\n const _url =\n this.host +\n `/receipt/${encodeURIComponent(String(receiptId))}/attachment/${encodeURIComponent(String(blobType))}` +\n '?ts=' +\n new Date().getTime() +\n '&rev=' +\n receiptRev\n let headers = await this.headers\n headers = headers.filter((h) => h.header !== 'Content-Type').concat(new XHR.Header('Content-Type', 'application/octet-stream'))\n return XHR.sendCommand('PUT', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => new Receipt(doc.body as JSON))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * @summary Creates a receipt's data attachment with compression metadata\n * @param receiptId id of a receipt\n * @param blobType receipt blob type\n * @param rev revision of the receipt\n * @param body content of the attachment\n * @param compressionAlgorithm the compression algorithm used on the client side, if any\n * @param triedCompressionAlgorithmsVersion a version string for the compression algorithms tried\n * @param realDataSize the real size of the data after decryption and decompression\n */\n async setReceiptDataAttachment(\n receiptId: string,\n blobType: string,\n rev: string,\n body: ArrayBuffer,\n compressionAlgorithm?: string,\n triedCompressionAlgorithmsVersion?: string,\n realDataSize?: number\n ): Promise<Receipt> {\n if (!rev) throw new Error('Receipt rev is required')\n\n const _url =\n this.host +\n `/receipt/${encodeURIComponent(String(receiptId))}/dataattachment/${encodeURIComponent(String(blobType))}` +\n '?ts=' +\n new Date().getTime() +\n '&rev=' +\n encodeURIComponent(String(rev)) +\n (compressionAlgorithm ? '&compressionAlgorithm=' + encodeURIComponent(String(compressionAlgorithm)) : '') +\n (triedCompressionAlgorithmsVersion\n ? '&triedCompressionAlgorithmsVersion=' + encodeURIComponent(String(triedCompressionAlgorithmsVersion))\n : '') +\n (realDataSize != null ? '&realDataSize=' + encodeURIComponent(String(realDataSize)) : '')\n let headers = await this.headers\n headers = headers\n .filter((h) => h.header !== 'Content-Type' && h.header !== 'Content-Length')\n .concat(new XHR.Header('Content-Type', 'application/octet-stream'))\n .concat(new XHR.Header('Content-Length', String(body.byteLength)))\n return XHR.sendCommand('PUT', _url, headers, body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => new Receipt(doc.body as JSON))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * @summary Get a receipt's attachment by blob type\n * @param receiptId id of the receipt\n * @param blobType the blob type of the attachment to retrieve\n */\n async getReceiptAttachmentByBlobType(receiptId: string, blobType: string): Promise<ArrayBuffer> {\n const _url =\n this.host +\n `/receipt/${encodeURIComponent(String(receiptId))}/attachment/ofType/${encodeURIComponent(String(blobType))}` +\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)\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 bulkShareReceipt(request: BulkShareOrUpdateMetadataParams): Promise<EntityBulkShareResult<Receipt>[]> {\n const _url = this.host + '/receipt/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<Receipt>(x, Receipt)))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * Retrieves the ids of all the receipts that currently have conflicting revisions and therefore need to\n * be resolved.\n * @summary List the ids of the receipts that have conflicts.\n * @return the ids of the receipts with unresolved conflicts.\n */\n async getConflictingEntitiesIds(): Promise<Array<string>> {\n const _url = this.host + `/receipt/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 receipt 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 receipt.\n * @param entityId the id of the receipt to retrieve the conflicts for.\n * @return the conflicting revisions of the receipt.\n */\n async getConflictsForEntity(entityId: string): Promise<Array<Receipt>> {\n const _url = this.host + `/receipt/conflicts/${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 Receipt(it)))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * Resolves a conflict by declaring which revision of the receipt 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 receipt.\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<Receipt>): Promise<ConflictResolutionResult<Receipt>> {\n const _url = this.host + `/receipt/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<Receipt>(doc.body, (x) => new Receipt(x)))\n .catch((err) => this.handleError(err))\n }\n}\n"]}
1
+ {"version":3,"file":"IccReceiptApi.js","sourceRoot":"","sources":["../../../icc-api/api/IccReceiptApi.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA;;;;;;;;;;GAUG;AACH,+BAA2B;AAC3B,0DAAsD;AACtD,8CAA0C;AAC1C,wFAA8G;AAC9G,qDAAiD;AAEjD,mFAA+E;AAI/E,gFAA4E;AAE5E,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,I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Ac,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;AAvTD,sCAuTC","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 { Receipt } from '../model/Receipt'\nimport { AuthenticationProvider, NoAuthenticationProvider } from '../../icc-x-api/auth/AuthenticationProvider'\nimport { iccRestApiPath } from './IccRestApiPath'\nimport { EntityShareOrMetadataUpdateRequest } from '../model/requests/EntityShareOrMetadataUpdateRequest'\nimport { EntityBulkShareResult } from '../model/requests/EntityBulkShareResult'\nimport { ListOfIds } from '../model/ListOfIds'\nimport { BulkShareOrUpdateMetadataParams } from '../model/requests/BulkShareOrUpdateMetadataParams'\nimport { ConflictResolutionRequest } from '../model/ConflictResolutionRequest'\nimport { ConflictResolutionResult } from '../model/ConflictResolutionResult'\n\nexport class IccReceiptApi {\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\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 receipt\n * @param body\n */\n async createReceipt(body?: Receipt): Promise<Receipt> {\n const _url = this.host + `/receipt` + '?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 Receipt(doc.body as JSON))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * @summary Deletes a batch of receipts.\n *\n * @param receiptIds a ListOfIds containing the ids of the receipts to delete.\n * @return a Promise that will resolve in an array of DocIdentifiers of the successfully deleted receipts.\n */\n async deleteReceipts(receiptIds: 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 + `/receipt/delete/batch` + '?ts=' + new Date().getTime(),\n headers,\n receiptIds,\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 receipt by id.\n *\n * @param receiptId the id of the receipt to delete.\n * @return a Promise that will resolve in the DocIdentifier of the deleted receipt.\n */\n async deleteReceipt(receiptId: string): Promise<DocIdentifier> {\n return XHR.sendCommand(\n 'DELETE',\n this.host + `/receipt/${encodeURIComponent(receiptId)}` + '?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 *\n * @summary Gets a receipt\n * @param receiptId\n */\n async getReceipt(receiptId: string): Promise<Receipt> {\n let _body = null\n\n const _url = this.host + `/receipt/${encodeURIComponent(String(receiptId))}` + '?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 Receipt(doc.body as JSON))\n .catch((err) => this.handleError(err))\n }\n\n /**\n *\n * @summary Get an attachment\n * @param receiptId\n * @param attachmentId\n * @param enckeys\n */\n async getReceiptAttachment(receiptId: string, attachmentId: string, enckeys?: null): Promise<ArrayBuffer> {\n if (enckeys) {\n throw new Error('Server-side encryption is not supported anymore.')\n }\n let _body = null\n\n const _url =\n this.host +\n `/receipt/${encodeURIComponent(String(receiptId))}/attachment/${encodeURIComponent(String(attachmentId))}` +\n '?ts=' +\n 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)\n .catch((err) => this.handleError(err))\n }\n\n /**\n *\n * @summary Gets a receipt\n * @param ref\n */\n async listByReference(ref: string): Promise<Array<Receipt>> {\n let _body = null\n\n const _url = this.host + `/receipt/byRef/${encodeURIComponent(String(ref))}` + '?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 Receipt(it)))\n .catch((err) => this.handleError(err))\n }\n\n /**\n *\n * @summary Updates a receipt\n * @param body\n */\n async modifyReceipt(body?: Receipt): Promise<Receipt> {\n let _body = null\n _body = body\n\n const _url = this.host + `/receipt` + '?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 Receipt(doc.body as JSON))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * @deprecated use setReceiptAttachmentForBlobType instead\n */\n async setReceiptAttachment(receiptId: string, receiptRev: string, blobType: string, enckeys?: null, body?: ArrayBuffer): Promise<Receipt> {\n if (enckeys) {\n throw new Error('Server-side encryption is not supported anymore.')\n }\n if (!body) {\n throw new Error('Attachment content is requred')\n }\n return this.setReceiptAttachmentForBlobType(receiptId, receiptRev, blobType, body)\n }\n\n /**\n * @summary Creates a receipt's attachment\n * @param receiptId id of a receipt\n * @param receiptRev rev of the receipt\n * @param blobType receipt blob type\n * @param body content of the attachment, already encrypted\n */\n async setReceiptAttachmentForBlobType(receiptId: string, receiptRev: string, blobType: string, body: ArrayBuffer): Promise<Receipt> {\n if (!receiptRev) throw new Error('Receipt rev is required')\n\n let _body = body\n\n const _url =\n this.host +\n `/receipt/${encodeURIComponent(String(receiptId))}/attachment/${encodeURIComponent(String(blobType))}` +\n '?ts=' +\n new Date().getTime() +\n '&rev=' +\n receiptRev\n let headers = await this.headers\n headers = headers.filter((h) => h.header !== 'Content-Type').concat(new XHR.Header('Content-Type', 'application/octet-stream'))\n return XHR.sendCommand('PUT', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => new Receipt(doc.body as JSON))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * @summary Creates a receipt's data attachment with compression metadata\n * @param receiptId id of a receipt\n * @param blobType receipt blob type\n * @param rev revision of the receipt\n * @param body content of the attachment\n * @param compressionAlgorithm the compression algorithm used on the client side, if any\n * @param triedCompressionAlgorithmsVersion a version string for the compression algorithms tried\n * @param realDataSize the real size of the data after decryption and decompression\n */\n async setReceiptDataAttachment(\n receiptId: string,\n blobType: string,\n rev: string,\n body: ArrayBuffer,\n compressionAlgorithm?: string,\n triedCompressionAlgorithmsVersion?: string,\n realDataSize?: number\n ): Promise<Receipt> {\n if (!rev) throw new Error('Receipt rev is required')\n\n const _url =\n this.host +\n `/receipt/${encodeURIComponent(String(receiptId))}/dataattachment/${encodeURIComponent(String(blobType))}` +\n '?ts=' +\n new Date().getTime() +\n '&rev=' +\n encodeURIComponent(String(rev)) +\n (compressionAlgorithm ? '&compressionAlgorithm=' + encodeURIComponent(String(compressionAlgorithm)) : '') +\n (triedCompressionAlgorithmsVersion\n ? '&triedCompressionAlgorithmsVersion=' + encodeURIComponent(String(triedCompressionAlgorithmsVersion))\n : '') +\n (realDataSize != null ? '&realDataSize=' + encodeURIComponent(String(realDataSize)) : '')\n let headers = await this.headers\n headers = headers\n .filter((h) => h.header !== 'Content-Type' && h.header !== 'Content-Length')\n .concat(new XHR.Header('Content-Type', 'application/octet-stream'))\n .concat(new XHR.Header('Content-Length', String(body.byteLength)))\n return XHR.sendCommand('PUT', _url, headers, body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => new Receipt(doc.body as JSON))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * @summary Get a receipt's attachment by blob type\n * @param receiptId id of the receipt\n * @param blobType the blob type of the attachment to retrieve\n */\n async getReceiptAttachmentByBlobType(receiptId: string, blobType: string): Promise<ArrayBuffer> {\n const _url =\n this.host +\n `/receipt/${encodeURIComponent(String(receiptId))}/attachment/ofType/${encodeURIComponent(String(blobType))}` +\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)\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 bulkShareReceipt(request: BulkShareOrUpdateMetadataParams): Promise<EntityBulkShareResult<Receipt>[]> {\n const _url = this.host + '/receipt/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<Receipt>(x, Receipt)))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * Retrieves the ids of all the receipts that currently have conflicting revisions and therefore need to\n * be resolved.\n * @summary List the ids of the receipts that have conflicts.\n * @return the ids of the receipts with unresolved conflicts.\n */\n async getConflictingEntitiesIds(): Promise<Array<string>> {\n const _url = this.host + `/receipt/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 receipt 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 receipt.\n * @param entityId the id of the receipt to retrieve the conflicts for.\n * @return the conflicting revisions of the receipt.\n */\n async getConflictsForEntity(entityId: string): Promise<Array<Receipt>> {\n const _url = this.host + `/receipt/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 Receipt(it)))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * Resolves a conflict by declaring which revision of the receipt 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 receipt.\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<Receipt>): Promise<ConflictResolutionResult<Receipt>> {\n const _url = this.host + `/receipt/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<Receipt>(doc.body, (x) => new Receipt(x)))\n .catch((err) => this.handleError(err))\n }\n}\n"]}
@@ -216,7 +216,7 @@ class IccTopicApi {
216
216
  */
217
217
  getConflictsForEntity(entityId) {
218
218
  return __awaiter(this, void 0, void 0, function* () {
219
- const _url = this.host + `/topic/conflicts/${encodeURIComponent(String(entityId))}` + '?ts=' + new Date().getTime();
219
+ const _url = this.host + `/topic/conflicts/of?entityId=${encodeURIComponent(String(entityId))}` + '&ts=' + new Date().getTime();
220
220
  let headers = yield this.headers;
221
221
  return XHR_1.XHR.sendCommand('GET', _url, headers, null, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())
222
222
  .then((doc) => doc.body.map((it) => new Topic_1.Topic(it)))
@@ -265,8 +265,8 @@ class IccTopicApi {
265
265
  getConflictsForEntityInGroup(groupId, entityId) {
266
266
  return __awaiter(this, void 0, void 0, function* () {
267
267
  const _url = this.host +
268
- `/topic/inGroup/${encodeURIComponent(String(groupId))}/conflicts/${encodeURIComponent(String(entityId))}` +
269
- '?ts=' +
268
+ `/topic/inGroup/${encodeURIComponent(String(groupId))}/conflicts/of?entityId=${encodeURIComponent(String(entityId))}` +
269
+ '&ts=' +
270
270
  new Date().getTime();
271
271
  let headers = yield this.headers;
272
272
  return XHR_1.XHR.sendCommand('GET', _url, headers, null, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())
@@ -1 +1 @@
1
- {"version":3,"file":"IccTopicApi.js","sourceRoot":"","sources":["../../../icc-api/api/IccTopicApi.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA;;;;;;;;;;GAUG;AACH,+BAA2B;AAC3B,0DAAsD;AACtD,0CAAiD;AAEjD,wFAA8G;AAC9G,qDAAiD;AAEjD,mFAA+E;AAE/E,oEAAgE;AAKhE,gFAA4E;AAE5E,MAAa,WAAW;IA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CAAC,CAAC,GAAG,EAAE,EAAE,CAAC,IAAI,CAAC,WAAW,CAAC,GAAG,CAAC,CAAC,CAAA;QAC1C,CAAC;KAAA;IAED;;;;;;OAMG;IACG,4BAA4B,CAAC,OAAe,EAAE,IAAsC;;YACxF,MAAM,IAAI,GAAG,IAAI,CAAC,IAAI,GAAG,kBAAkB,kBAAkB,CAAC,MAAM,CAAC,OAAO,CAAC,CAAC,mBAAmB,GAAG,MAAM,GAAG,IAAI,IAAI,EAAE,CAAC,OAAO,EAAE,CAAA;YACjI,IAAI,OAAO,GAAG,MAAM,IAAI,CAAC,OAAO,CAAA;YAChC,OAAO,GAAG,OAAO,CAAC,MAAM,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,MAAM,KAAK,cAAc,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,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;AAvTD,kCAuTC","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 { Topic, TopicRole } from '../model/Topic'\nimport { ListOfIds } from '../model/ListOfIds'\nimport { AuthenticationProvider, NoAuthenticationProvider } from '../../icc-x-api/auth/AuthenticationProvider'\nimport { iccRestApiPath } from './IccRestApiPath'\nimport { EntityShareOrMetadataUpdateRequest } from '../model/requests/EntityShareOrMetadataUpdateRequest'\nimport { EntityBulkShareResult } from '../model/requests/EntityBulkShareResult'\nimport { FilterChainTopic } from '../model/FilterChainTopic'\nimport { PaginatedListTopic } from '../model/PaginatedListTopic'\nimport { AbstractFilterTopic } from '../model/AbstractFilterTopic'\nimport { TimingInfo } from '../model/TimingInfo'\nimport { BulkShareOrUpdateMetadataParams } from '../model/requests/BulkShareOrUpdateMetadataParams'\nimport { ConflictResolutionRequest } from '../model/ConflictResolutionRequest'\nimport { ConflictResolutionResult } from '../model/ConflictResolutionResult'\n\nexport class IccTopicApi {\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\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 Gets a topic\n * @param topicId\n */\n async getTopic(topicId: string): Promise<Topic> {\n const _body = null\n\n const _url = this.host + `/topic/${encodeURIComponent(String(topicId))}` + '?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 Topic(doc.body as JSON))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * Keys must be delimited by coma\n * @summary Get a list of topics by ids\n * @param body\n */\n async getTopics(body: ListOfIds): Promise<Array<Topic>> {\n const _url = this.host + `/topic/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 Topic(it)))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * Returns an instance of created topic.\n * @summary Create a topic with the current user\n * @param body\n */\n async createTopic(body: Topic): Promise<Topic> {\n const _url = this.host + `/topic` + '?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 Topic(doc.body as JSON))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * Returns the modified topic.\n * @summary Modify a topic\n * @param body\n */\n async modifyTopic(body: Topic): Promise<Topic> {\n const _url = this.host + `/topic` + '?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 Topic(doc.body as JSON))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * @summary Deletes a topic by id.\n *\n * @param topicId the id of the topic to delete\n * @return a Promise that will resolve in the DocIdentifier of the deleted topic.\n */\n async deleteTopic(topicId: string): Promise<DocIdentifier> {\n const _url = this.host + `/topic/${encodeURIComponent(topicId)}` + '?ts=' + new Date().getTime()\n let headers = await this.headers\n return XHR.sendCommand('DELETE', _url, headers, null, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => new DocIdentifier(doc.body))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * Response is a set containing the ID's of deleted topics.\n * @summary Delete topics.\n * @param body\n */\n async deleteTopics(body: ListOfIds): Promise<Array<DocIdentifier>> {\n const _url = this.host + `/topic/delete/batch` + '?ts=' + new Date().getTime()\n const headers = (await this.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 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 bulkShareTopics(request: BulkShareOrUpdateMetadataParams): Promise<EntityBulkShareResult<Topic>[]> {\n const _url = this.host + '/topic/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<Topic>(x, Topic)))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * Returns a list of topics along with next start keys and Document ID. If the nextStartKey is Null it means that this is the last page.\n * @summary List topics for the current user (HcParty) or the given hcparty in the filter\n * @param body\n * @param startDocumentId A Topic document ID\n * @param limit Number of rows\n * @param collectTiming if true, include server-side filter timing information in the response\n */\n filterTopicsBy(body: FilterChainTopic, startDocumentId?: string, limit?: number, collectTiming?: false): Promise<PaginatedListTopic>\n filterTopicsBy(body: FilterChainTopic, startDocumentId?: string, limit?: number, collectTiming?: true): Promise<PaginatedListTopic & TimingInfo>\n async filterTopicsBy(\n body: FilterChainTopic,\n startDocumentId?: string,\n limit?: number,\n collectTiming: boolean = false\n ): Promise<PaginatedListTopic> {\n const _url =\n this.host +\n `/topic/filter` +\n '?ts=' +\n new Date().getTime() +\n (startDocumentId ? '&startDocumentId=' + encodeURIComponent(String(startDocumentId)) : '') +\n (limit ? '&limit=' + encodeURIComponent(String(limit)) : '')\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 PaginatedListTopic(doc.body as JSON), collectTiming ? { responseHeaders: doc.responseHeaders } : {}))\n .catch((err) => this.handleError(err))\n }\n\n /**\n *\n * @summary Get ids of topics 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 matchTopicsBy(body: AbstractFilterTopic, collectTiming?: false): Promise<Array<string>>\n matchTopicsBy(body: AbstractFilterTopic, collectTiming?: true): Promise<Array<string> & TimingInfo>\n async matchTopicsBy(body: AbstractFilterTopic, collectTiming: boolean = false): Promise<Array<string>> {\n const _url = this.host + `/topic/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 async addParticipant(body: { dataOwnerId: string; topicRole: TopicRole }, topicId: string): Promise<Topic> {\n const _url = this.host + `/topic/${topicId}/addParticipant` + '?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 Topic(doc.body as JSON))\n .catch((err) => this.handleError(err))\n }\n\n async removeParticipant(body: { dataOwnerId: string }, topicId: string): Promise<Topic> {\n const _url = this.host + `/topic/${topicId}/removeParticipant` + '?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 Topic(doc.body as JSON))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * Retrieves the ids of all the topics that currently have conflicting revisions and therefore need to\n * be resolved.\n * @summary List the ids of the topics that have conflicts.\n * @return the ids of the topics with unresolved conflicts.\n */\n async getConflictingEntitiesIds(): Promise<Array<string>> {\n const _url = this.host + `/topic/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 topic 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 topic.\n * @param entityId the id of the topic to retrieve the conflicts for.\n * @return the conflicting revisions of the topic.\n */\n async getConflictsForEntity(entityId: string): Promise<Array<Topic>> {\n const _url = this.host + `/topic/conflicts/${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 Topic(it)))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * Resolves a conflict by declaring which revision of the topic 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 topic.\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<Topic>): Promise<ConflictResolutionResult<Topic>> {\n const _url = this.host + `/topic/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<Topic>(doc.body, (x) => new Topic(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 topics that have conflicts, in the given group.\n * @param groupId the id of the group to look into.\n * @return the ids of the topics with unresolved conflicts in the group.\n */\n async getConflictingEntitiesIdsInGroup(groupId: string): Promise<Array<string>> {\n const _url = this.host + `/topic/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 topic, in the given group.\n * @param groupId the id of the group the topic belongs to.\n * @param entityId the id of the topic to retrieve the conflicts for.\n * @return the conflicting revisions of the topic.\n */\n async getConflictsForEntityInGroup(groupId: string, entityId: string): Promise<Array<Topic>> {\n const _url =\n this.host +\n `/topic/inGroup/${encodeURIComponent(String(groupId))}/conflicts/${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 Topic(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 topic, in the given group.\n * @param groupId the id of the group the topic 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<Topic>): Promise<ConflictResolutionResult<Topic>> {\n const _url = this.host + `/topic/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<Topic>(doc.body, (x) => new Topic(x)))\n .catch((err) => this.handleError(err))\n }\n}\n"]}
1
+ {"version":3,"file":"IccTopicApi.js","sourceRoot":"","sources":["../../../icc-api/api/IccTopicApi.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA;;;;;;;;;;GAUG;AACH,+BAA2B;AAC3B,0DAAsD;AACtD,0CAAiD;AAEjD,wFAA8G;AAC9G,qDAAiD;AAEjD,mFAA+E;AAE/E,oEAAgE;AAKhE,gFAA4E;AAE5E,MAAa,WAAW;IAMtB,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,CA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,GAAG,IAAI,IAAI,EAAE,CAAC,OAAO,EAAE,CAAA;YACjI,IAAI,OAAO,GAAG,MAAM,IAAI,CAAC,OAAO,CAAA;YAChC,OAAO,GAAG,OAAO,CAAC,MAAM,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,MAAM,KAAK,cAAc,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,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;AAvTD,kCAuTC","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 { Topic, TopicRole } from '../model/Topic'\nimport { ListOfIds } from '../model/ListOfIds'\nimport { AuthenticationProvider, NoAuthenticationProvider } from '../../icc-x-api/auth/AuthenticationProvider'\nimport { iccRestApiPath } from './IccRestApiPath'\nimport { EntityShareOrMetadataUpdateRequest } from '../model/requests/EntityShareOrMetadataUpdateRequest'\nimport { EntityBulkShareResult } from '../model/requests/EntityBulkShareResult'\nimport { FilterChainTopic } from '../model/FilterChainTopic'\nimport { PaginatedListTopic } from '../model/PaginatedListTopic'\nimport { AbstractFilterTopic } from '../model/AbstractFilterTopic'\nimport { TimingInfo } from '../model/TimingInfo'\nimport { BulkShareOrUpdateMetadataParams } from '../model/requests/BulkShareOrUpdateMetadataParams'\nimport { ConflictResolutionRequest } from '../model/ConflictResolutionRequest'\nimport { ConflictResolutionResult } from '../model/ConflictResolutionResult'\n\nexport class IccTopicApi {\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\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 Gets a topic\n * @param topicId\n */\n async getTopic(topicId: string): Promise<Topic> {\n const _body = null\n\n const _url = this.host + `/topic/${encodeURIComponent(String(topicId))}` + '?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 Topic(doc.body as JSON))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * Keys must be delimited by coma\n * @summary Get a list of topics by ids\n * @param body\n */\n async getTopics(body: ListOfIds): Promise<Array<Topic>> {\n const _url = this.host + `/topic/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 Topic(it)))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * Returns an instance of created topic.\n * @summary Create a topic with the current user\n * @param body\n */\n async createTopic(body: Topic): Promise<Topic> {\n const _url = this.host + `/topic` + '?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 Topic(doc.body as JSON))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * Returns the modified topic.\n * @summary Modify a topic\n * @param body\n */\n async modifyTopic(body: Topic): Promise<Topic> {\n const _url = this.host + `/topic` + '?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 Topic(doc.body as JSON))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * @summary Deletes a topic by id.\n *\n * @param topicId the id of the topic to delete\n * @return a Promise that will resolve in the DocIdentifier of the deleted topic.\n */\n async deleteTopic(topicId: string): Promise<DocIdentifier> {\n const _url = this.host + `/topic/${encodeURIComponent(topicId)}` + '?ts=' + new Date().getTime()\n let headers = await this.headers\n return XHR.sendCommand('DELETE', _url, headers, null, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())\n .then((doc) => new DocIdentifier(doc.body))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * Response is a set containing the ID's of deleted topics.\n * @summary Delete topics.\n * @param body\n */\n async deleteTopics(body: ListOfIds): Promise<Array<DocIdentifier>> {\n const _url = this.host + `/topic/delete/batch` + '?ts=' + new Date().getTime()\n const headers = (await this.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 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 bulkShareTopics(request: BulkShareOrUpdateMetadataParams): Promise<EntityBulkShareResult<Topic>[]> {\n const _url = this.host + '/topic/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<Topic>(x, Topic)))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * Returns a list of topics along with next start keys and Document ID. If the nextStartKey is Null it means that this is the last page.\n * @summary List topics for the current user (HcParty) or the given hcparty in the filter\n * @param body\n * @param startDocumentId A Topic document ID\n * @param limit Number of rows\n * @param collectTiming if true, include server-side filter timing information in the response\n */\n filterTopicsBy(body: FilterChainTopic, startDocumentId?: string, limit?: number, collectTiming?: false): Promise<PaginatedListTopic>\n filterTopicsBy(body: FilterChainTopic, startDocumentId?: string, limit?: number, collectTiming?: true): Promise<PaginatedListTopic & TimingInfo>\n async filterTopicsBy(\n body: FilterChainTopic,\n startDocumentId?: string,\n limit?: number,\n collectTiming: boolean = false\n ): Promise<PaginatedListTopic> {\n const _url =\n this.host +\n `/topic/filter` +\n '?ts=' +\n new Date().getTime() +\n (startDocumentId ? '&startDocumentId=' + encodeURIComponent(String(startDocumentId)) : '') +\n (limit ? '&limit=' + encodeURIComponent(String(limit)) : '')\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 PaginatedListTopic(doc.body as JSON), collectTiming ? { responseHeaders: doc.responseHeaders } : {}))\n .catch((err) => this.handleError(err))\n }\n\n /**\n *\n * @summary Get ids of topics 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 matchTopicsBy(body: AbstractFilterTopic, collectTiming?: false): Promise<Array<string>>\n matchTopicsBy(body: AbstractFilterTopic, collectTiming?: true): Promise<Array<string> & TimingInfo>\n async matchTopicsBy(body: AbstractFilterTopic, collectTiming: boolean = false): Promise<Array<string>> {\n const _url = this.host + `/topic/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 async addParticipant(body: { dataOwnerId: string; topicRole: TopicRole }, topicId: string): Promise<Topic> {\n const _url = this.host + `/topic/${topicId}/addParticipant` + '?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 Topic(doc.body as JSON))\n .catch((err) => this.handleError(err))\n }\n\n async removeParticipant(body: { dataOwnerId: string }, topicId: string): Promise<Topic> {\n const _url = this.host + `/topic/${topicId}/removeParticipant` + '?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 Topic(doc.body as JSON))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * Retrieves the ids of all the topics that currently have conflicting revisions and therefore need to\n * be resolved.\n * @summary List the ids of the topics that have conflicts.\n * @return the ids of the topics with unresolved conflicts.\n */\n async getConflictingEntitiesIds(): Promise<Array<string>> {\n const _url = this.host + `/topic/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 topic 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 topic.\n * @param entityId the id of the topic to retrieve the conflicts for.\n * @return the conflicting revisions of the topic.\n */\n async getConflictsForEntity(entityId: string): Promise<Array<Topic>> {\n const _url = this.host + `/topic/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 Topic(it)))\n .catch((err) => this.handleError(err))\n }\n\n /**\n * Resolves a conflict by declaring which revision of the topic 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 topic.\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<Topic>): Promise<ConflictResolutionResult<Topic>> {\n const _url = this.host + `/topic/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<Topic>(doc.body, (x) => new Topic(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 topics that have conflicts, in the given group.\n * @param groupId the id of the group to look into.\n * @return the ids of the topics with unresolved conflicts in the group.\n */\n async getConflictingEntitiesIdsInGroup(groupId: string): Promise<Array<string>> {\n const _url = this.host + `/topic/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 topic, in the given group.\n * @param groupId the id of the group the topic belongs to.\n * @param entityId the id of the topic to retrieve the conflicts for.\n * @return the conflicting revisions of the topic.\n */\n async getConflictsForEntityInGroup(groupId: string, entityId: string): Promise<Array<Topic>> {\n const _url =\n this.host +\n `/topic/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 Topic(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 topic, in the given group.\n * @param groupId the id of the group the topic 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<Topic>): Promise<ConflictResolutionResult<Topic>> {\n const _url = this.host + `/topic/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<Topic>(doc.body, (x) => new Topic(x)))\n .catch((err) => this.handleError(err))\n }\n}\n"]}
@@ -587,7 +587,7 @@ class IccUserApi {
587
587
  */
588
588
  getConflictsForEntity(entityId) {
589
589
  return __awaiter(this, void 0, void 0, function* () {
590
- const _url = this.host + `/user/conflicts/${encodeURIComponent(String(entityId))}` + '?ts=' + new Date().getTime();
590
+ const _url = this.host + `/user/conflicts/of?entityId=${encodeURIComponent(String(entityId))}` + '&ts=' + new Date().getTime();
591
591
  let headers = yield this.headers;
592
592
  return XHR_1.XHR.sendCommand('GET', _url, headers, null, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())
593
593
  .then((doc) => doc.body.map((it) => new User_1.User(it)))