@oystehr/sdk 4.3.10 → 4.3.12

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 (93) hide show
  1. package/dist/cjs/client/client.cjs +12 -5
  2. package/dist/cjs/client/client.cjs.map +1 -1
  3. package/dist/cjs/client/client.d.ts +5 -0
  4. package/dist/cjs/index.min.cjs +1 -1
  5. package/dist/cjs/index.min.cjs.map +1 -1
  6. package/dist/cjs/resources/classes/erx.cjs +8 -0
  7. package/dist/cjs/resources/classes/erx.cjs.map +1 -1
  8. package/dist/cjs/resources/classes/erx.d.ts +7 -1
  9. package/dist/cjs/resources/classes/fhir-ext.cjs +27 -4
  10. package/dist/cjs/resources/classes/fhir-ext.cjs.map +1 -1
  11. package/dist/cjs/resources/classes/fhir-ext.d.ts +23 -3
  12. package/dist/cjs/resources/classes/fhir.cjs +31 -0
  13. package/dist/cjs/resources/classes/fhir.cjs.map +1 -1
  14. package/dist/cjs/resources/classes/fhir.d.ts +31 -0
  15. package/dist/cjs/resources/classes/rcm.cjs +9 -0
  16. package/dist/cjs/resources/classes/rcm.cjs.map +1 -1
  17. package/dist/cjs/resources/classes/rcm.d.ts +8 -1
  18. package/dist/cjs/resources/classes/terminology.cjs +9 -0
  19. package/dist/cjs/resources/classes/terminology.cjs.map +1 -1
  20. package/dist/cjs/resources/classes/terminology.d.ts +8 -1
  21. package/dist/cjs/resources/classes/z3.cjs +9 -0
  22. package/dist/cjs/resources/classes/z3.cjs.map +1 -1
  23. package/dist/cjs/resources/classes/z3.d.ts +8 -1
  24. package/dist/cjs/resources/types/ErxGetMedicationHistoryResponse.d.ts +1 -1
  25. package/dist/cjs/resources/types/ErxGetPharmacyParams.d.ts +3 -0
  26. package/dist/cjs/resources/types/ErxGetPharmacyResponse.d.ts +16 -0
  27. package/dist/cjs/resources/types/ErxSearchPharmaciesResponse.d.ts +2 -2
  28. package/dist/cjs/resources/types/LabOrderSubmitParams.d.ts +4 -0
  29. package/dist/cjs/resources/types/RcmProcessEraParams.d.ts +6 -0
  30. package/dist/cjs/resources/types/RcmProcessEraResponse.d.ts +5 -0
  31. package/dist/cjs/resources/types/TerminologySearchIcd10Params.d.ts +9 -0
  32. package/dist/cjs/resources/types/TerminologySearchIcd10Response.d.ts +27 -0
  33. package/dist/cjs/resources/types/Z3EmptyBucketParams.d.ts +3 -0
  34. package/dist/cjs/resources/types/Z3EmptyBucketResponse.d.ts +9 -0
  35. package/dist/cjs/resources/types/fhir.d.ts +13 -0
  36. package/dist/cjs/resources/types/index.d.ts +8 -0
  37. package/dist/esm/client/client.d.ts +5 -0
  38. package/dist/esm/client/client.js +12 -5
  39. package/dist/esm/client/client.js.map +1 -1
  40. package/dist/esm/index.min.js +1 -1
  41. package/dist/esm/index.min.js.map +1 -1
  42. package/dist/esm/resources/classes/erx.d.ts +7 -1
  43. package/dist/esm/resources/classes/erx.js +8 -0
  44. package/dist/esm/resources/classes/erx.js.map +1 -1
  45. package/dist/esm/resources/classes/fhir-ext.d.ts +23 -3
  46. package/dist/esm/resources/classes/fhir-ext.js +27 -4
  47. package/dist/esm/resources/classes/fhir-ext.js.map +1 -1
  48. package/dist/esm/resources/classes/fhir.d.ts +31 -0
  49. package/dist/esm/resources/classes/fhir.js +31 -0
  50. package/dist/esm/resources/classes/fhir.js.map +1 -1
  51. package/dist/esm/resources/classes/rcm.d.ts +8 -1
  52. package/dist/esm/resources/classes/rcm.js +9 -0
  53. package/dist/esm/resources/classes/rcm.js.map +1 -1
  54. package/dist/esm/resources/classes/terminology.d.ts +8 -1
  55. package/dist/esm/resources/classes/terminology.js +9 -0
  56. package/dist/esm/resources/classes/terminology.js.map +1 -1
  57. package/dist/esm/resources/classes/z3.d.ts +8 -1
  58. package/dist/esm/resources/classes/z3.js +9 -0
  59. package/dist/esm/resources/classes/z3.js.map +1 -1
  60. package/dist/esm/resources/types/ErxGetMedicationHistoryResponse.d.ts +1 -1
  61. package/dist/esm/resources/types/ErxGetPharmacyParams.d.ts +3 -0
  62. package/dist/esm/resources/types/ErxGetPharmacyResponse.d.ts +16 -0
  63. package/dist/esm/resources/types/ErxSearchPharmaciesResponse.d.ts +2 -2
  64. package/dist/esm/resources/types/LabOrderSubmitParams.d.ts +4 -0
  65. package/dist/esm/resources/types/RcmProcessEraParams.d.ts +6 -0
  66. package/dist/esm/resources/types/RcmProcessEraResponse.d.ts +5 -0
  67. package/dist/esm/resources/types/TerminologySearchIcd10Params.d.ts +9 -0
  68. package/dist/esm/resources/types/TerminologySearchIcd10Response.d.ts +27 -0
  69. package/dist/esm/resources/types/Z3EmptyBucketParams.d.ts +3 -0
  70. package/dist/esm/resources/types/Z3EmptyBucketResponse.d.ts +9 -0
  71. package/dist/esm/resources/types/fhir.d.ts +13 -0
  72. package/dist/esm/resources/types/index.d.ts +8 -0
  73. package/package.json +1 -1
  74. package/src/client/client.ts +22 -8
  75. package/src/resources/classes/erx.ts +10 -0
  76. package/src/resources/classes/fhir-ext.ts +52 -7
  77. package/src/resources/classes/fhir.ts +31 -0
  78. package/src/resources/classes/rcm.ts +11 -0
  79. package/src/resources/classes/terminology.ts +14 -0
  80. package/src/resources/classes/z3.ts +11 -0
  81. package/src/resources/types/ErxGetMedicationHistoryResponse.ts +1 -1
  82. package/src/resources/types/ErxGetPharmacyParams.ts +5 -0
  83. package/src/resources/types/ErxGetPharmacyResponse.ts +18 -0
  84. package/src/resources/types/ErxSearchPharmaciesResponse.ts +2 -2
  85. package/src/resources/types/LabOrderSubmitParams.ts +4 -0
  86. package/src/resources/types/RcmProcessEraParams.ts +8 -0
  87. package/src/resources/types/RcmProcessEraResponse.ts +7 -0
  88. package/src/resources/types/TerminologySearchIcd10Params.ts +11 -0
  89. package/src/resources/types/TerminologySearchIcd10Response.ts +29 -0
  90. package/src/resources/types/Z3EmptyBucketParams.ts +5 -0
  91. package/src/resources/types/Z3EmptyBucketResponse.ts +11 -0
  92. package/src/resources/types/fhir.ts +13 -0
  93. package/src/resources/types/index.ts +8 -0
@@ -25,9 +25,40 @@ export declare class Fhir extends SDKResource {
25
25
  update: typeof ext.update;
26
26
  patch: typeof ext.patch;
27
27
  delete: typeof ext.delete;
28
+ /**
29
+ * Fetches the status of an async job. If the job is still in progress, returns an object with status 202. If the job is completed, returns the job result with status 200. If the job has failed, returns an object with status 500 and an OperationOutcome resource describing the failure. If the job has expired, returns an object with status 410.
30
+ * @param this The SDKResource context (this is an extension method and should be called with the SDKResource instance as the context, e.g. `sdkResource.getAsyncJob(jobId)`)
31
+ * @param jobId The ID of the async job to fetch
32
+ * @param request Optional OystehrClientRequest for authentication and headers
33
+ * @returns A Promise that resolves to the FhirAsyncJobStatus
34
+ */
28
35
  getAsyncJob: typeof ext.getAsyncJob;
36
+ /**
37
+ * Waits for an async job to complete by polling its status until it reaches a terminal state (success, failure, or expiration) or the specified timeout is reached. Returns the final job status. Throws if the job fails, expires, or does not complete within the timeout.
38
+ * @param this The SDKResource context (this is an extension method and should be called with the SDKResource instance as the context, e.g. `sdkResource.waitForAsyncJob(jobId)`)
39
+ * @param jobId The ID of the async job to wait for
40
+ * @param options Optional FhirAsyncWaitOptions to configure polling behavior
41
+ * @param request Optional OystehrClientRequest for authentication and headers
42
+ * @returns A Promise that resolves to the final FhirAsyncJobStatus
43
+ */
29
44
  waitForAsyncJob: typeof ext.waitForAsyncJob;
45
+ /**
46
+ * Waits for an async job to complete and retrieves the bulk output manifest and files. Throws if the job fails, expires, or does not complete within the specified timeout.
47
+ * @param this The SDKResource context (this is an extension method and should be called with the SDKResource instance as the context, e.g. `sdkResource.waitForAsyncBulkOutput(jobId)`)
48
+ * @param jobId The ID of the async job to wait for
49
+ * @param options Optional FhirAsyncWaitOptions to configure polling behavior
50
+ * @param request Optional OystehrClientRequest for authentication and headers
51
+ * @returns A Promise that resolves to a FhirAsyncBulkOutputResult containing the bulk output manifest and files
52
+ */
30
53
  waitForAsyncBulkOutput: typeof ext.waitForAsyncBulkOutput;
54
+ /**
55
+ * Wrapper around waitForAsyncBulkOutput that transforms the retrieved bulk output files into a single Bundle resource containing all the output resources as entries. This is a convenience method for use cases where you want to work with the bulk output as a Bundle, but it may not be efficient for large outputs due to the overhead of downloading and parsing all files and constructing the Bundle in memory.
56
+ * Can be slow due to downloading and parsing potentially large NDJSON files, so use only if you need the full output as a Bundle resource. For more efficient processing of large bulk outputs, use waitForAsyncBulkOutput directly.
57
+ * @param jobId the ID of the async job to wait for
58
+ * @param options optional FhirAsyncWaitOptions to configure polling behavior
59
+ * @param request optional OystehrClientRequest for authentication and headers
60
+ * @returns a Promise that resolves to a Bundle containing all resources from the bulk output
61
+ */
31
62
  waitForAsyncBulkBundle: typeof ext.waitForAsyncBulkBundle;
32
63
  cancelAsyncJob: typeof ext.cancelAsyncJob;
33
64
  history: typeof ext.history;
@@ -30,9 +30,40 @@ class Fhir extends SDKResource {
30
30
  update = update;
31
31
  patch = patch;
32
32
  delete = del;
33
+ /**
34
+ * Fetches the status of an async job. If the job is still in progress, returns an object with status 202. If the job is completed, returns the job result with status 200. If the job has failed, returns an object with status 500 and an OperationOutcome resource describing the failure. If the job has expired, returns an object with status 410.
35
+ * @param this The SDKResource context (this is an extension method and should be called with the SDKResource instance as the context, e.g. `sdkResource.getAsyncJob(jobId)`)
36
+ * @param jobId The ID of the async job to fetch
37
+ * @param request Optional OystehrClientRequest for authentication and headers
38
+ * @returns A Promise that resolves to the FhirAsyncJobStatus
39
+ */
33
40
  getAsyncJob = getAsyncJob;
41
+ /**
42
+ * Waits for an async job to complete by polling its status until it reaches a terminal state (success, failure, or expiration) or the specified timeout is reached. Returns the final job status. Throws if the job fails, expires, or does not complete within the timeout.
43
+ * @param this The SDKResource context (this is an extension method and should be called with the SDKResource instance as the context, e.g. `sdkResource.waitForAsyncJob(jobId)`)
44
+ * @param jobId The ID of the async job to wait for
45
+ * @param options Optional FhirAsyncWaitOptions to configure polling behavior
46
+ * @param request Optional OystehrClientRequest for authentication and headers
47
+ * @returns A Promise that resolves to the final FhirAsyncJobStatus
48
+ */
34
49
  waitForAsyncJob = waitForAsyncJob;
50
+ /**
51
+ * Waits for an async job to complete and retrieves the bulk output manifest and files. Throws if the job fails, expires, or does not complete within the specified timeout.
52
+ * @param this The SDKResource context (this is an extension method and should be called with the SDKResource instance as the context, e.g. `sdkResource.waitForAsyncBulkOutput(jobId)`)
53
+ * @param jobId The ID of the async job to wait for
54
+ * @param options Optional FhirAsyncWaitOptions to configure polling behavior
55
+ * @param request Optional OystehrClientRequest for authentication and headers
56
+ * @returns A Promise that resolves to a FhirAsyncBulkOutputResult containing the bulk output manifest and files
57
+ */
35
58
  waitForAsyncBulkOutput = waitForAsyncBulkOutput;
59
+ /**
60
+ * Wrapper around waitForAsyncBulkOutput that transforms the retrieved bulk output files into a single Bundle resource containing all the output resources as entries. This is a convenience method for use cases where you want to work with the bulk output as a Bundle, but it may not be efficient for large outputs due to the overhead of downloading and parsing all files and constructing the Bundle in memory.
61
+ * Can be slow due to downloading and parsing potentially large NDJSON files, so use only if you need the full output as a Bundle resource. For more efficient processing of large bulk outputs, use waitForAsyncBulkOutput directly.
62
+ * @param jobId the ID of the async job to wait for
63
+ * @param options optional FhirAsyncWaitOptions to configure polling behavior
64
+ * @param request optional OystehrClientRequest for authentication and headers
65
+ * @returns a Promise that resolves to a Bundle containing all resources from the bulk output
66
+ */
36
67
  waitForAsyncBulkBundle = waitForAsyncBulkBundle;
37
68
  cancelAsyncJob = cancelAsyncJob;
38
69
  history = history;
@@ -1 +1 @@
1
- {"version":3,"file":"fhir.js","sources":["../../../../src/resources/classes/fhir.ts"],"sourcesContent":["// AUTOGENERATED -- DO NOT EDIT\n\nimport { SDKResource } from '../../client/client';\nimport { OystehrConfig } from '../../config';\nimport * as ext from './fhir-ext';\n\nexport class Fhir extends SDKResource {\n constructor(config: OystehrConfig) {\n super(config);\n }\n #baseUrlThunk(): string {\n return this.config.services?.['fhirApiUrl'] ?? 'https://fhir-api.zapehr.com';\n }\n /**\n * Performs a FHIR search and returns the results as a Bundle resource\n * @param options FHIR resource type and FHIR search parameters\n * @param request optional OystehrClientRequest object\n * @returns FHIR Bundle resource\n */\n search = ext.search;\n /**\n * Performs an iterative FHIR search over initial request and following \"next\" urls,\n * collecting all pages into a single Bundle.\n * @param params FHIR search parameters plus optional pageSize that will overwrite _count in params\n * @param request optional OystehrClientRequest object\n * @returns FHIR Bundle resource that contains all entries across all pages. Bundle-level metadata\n * (id, meta, total, etc.) is taken from the first page.\n */\n searchAndGetAllPages = ext.searchAndGetAllPages;\n create = ext.create;\n get = ext.get;\n update = ext.update;\n patch = ext.patch;\n delete = ext.delete;\n getAsyncJob = ext.getAsyncJob;\n waitForAsyncJob = ext.waitForAsyncJob;\n waitForAsyncBulkOutput = ext.waitForAsyncBulkOutput;\n waitForAsyncBulkBundle = ext.waitForAsyncBulkBundle;\n cancelAsyncJob = ext.cancelAsyncJob;\n history = ext.history;\n batch = ext.batch;\n transaction = ext.transaction;\n generateFriendlyPatientId = ext.generateFriendlyPatientId;\n formatAddress = ext.formatAddress;\n formatHumanName = ext.formatHumanName;\n}\n"],"names":["ext.search","ext.searchAndGetAllPages","ext.create","ext.get","ext.update","ext.patch","ext.delete","ext.getAsyncJob","ext.waitForAsyncJob","ext.waitForAsyncBulkOutput","ext.waitForAsyncBulkBundle","ext.cancelAsyncJob","ext.history","ext.batch","ext.transaction","ext.generateFriendlyPatientId","ext.formatAddress","ext.formatHumanName"],"mappings":";;;AAAA;AAMM,MAAO,IAAK,SAAQ,WAAW,CAAA;AACnC,IAAA,WAAA,CAAY,MAAqB,EAAA;QAC/B,KAAK,CAAC,MAAM,CAAC;IACf;IACA,aAAa,GAAA;QACX,OAAO,IAAI,CAAC,MAAM,CAAC,QAAQ,GAAG,YAAY,CAAC,IAAI,6BAA6B;IAC9E;AACA;;;;;AAKG;AACH,IAAA,MAAM,GAAGA,MAAU;AACnB;;;;;;;AAOG;AACH,IAAA,oBAAoB,GAAGC,oBAAwB;AAC/C,IAAA,MAAM,GAAGC,MAAU;AACnB,IAAA,GAAG,GAAGC,GAAO;AACb,IAAA,MAAM,GAAGC,MAAU;AACnB,IAAA,KAAK,GAAGC,KAAS;AACjB,IAAA,MAAM,GAAGC,GAAU;AACnB,IAAA,WAAW,GAAGC,WAAe;AAC7B,IAAA,eAAe,GAAGC,eAAmB;AACrC,IAAA,sBAAsB,GAAGC,sBAA0B;AACnD,IAAA,sBAAsB,GAAGC,sBAA0B;AACnD,IAAA,cAAc,GAAGC,cAAkB;AACnC,IAAA,OAAO,GAAGC,OAAW;AACrB,IAAA,KAAK,GAAGC,KAAS;AACjB,IAAA,WAAW,GAAGC,WAAe;AAC7B,IAAA,yBAAyB,GAAGC,yBAA6B;AACzD,IAAA,aAAa,GAAGC,aAAiB;AACjC,IAAA,eAAe,GAAGC,eAAmB;AACtC;;;;"}
1
+ {"version":3,"file":"fhir.js","sources":["../../../../src/resources/classes/fhir.ts"],"sourcesContent":["// AUTOGENERATED -- DO NOT EDIT\n\nimport { SDKResource } from '../../client/client';\nimport { OystehrConfig } from '../../config';\nimport * as ext from './fhir-ext';\n\nexport class Fhir extends SDKResource {\n constructor(config: OystehrConfig) {\n super(config);\n }\n #baseUrlThunk(): string {\n return this.config.services?.['fhirApiUrl'] ?? 'https://fhir-api.zapehr.com';\n }\n /**\n * Performs a FHIR search and returns the results as a Bundle resource\n * @param options FHIR resource type and FHIR search parameters\n * @param request optional OystehrClientRequest object\n * @returns FHIR Bundle resource\n */\n search = ext.search;\n /**\n * Performs an iterative FHIR search over initial request and following \"next\" urls,\n * collecting all pages into a single Bundle.\n * @param params FHIR search parameters plus optional pageSize that will overwrite _count in params\n * @param request optional OystehrClientRequest object\n * @returns FHIR Bundle resource that contains all entries across all pages. Bundle-level metadata\n * (id, meta, total, etc.) is taken from the first page.\n */\n searchAndGetAllPages = ext.searchAndGetAllPages;\n create = ext.create;\n get = ext.get;\n update = ext.update;\n patch = ext.patch;\n delete = ext.delete;\n /**\n * Fetches the status of an async job. If the job is still in progress, returns an object with status 202. If the job is completed, returns the job result with status 200. If the job has failed, returns an object with status 500 and an OperationOutcome resource describing the failure. If the job has expired, returns an object with status 410.\n * @param this The SDKResource context (this is an extension method and should be called with the SDKResource instance as the context, e.g. `sdkResource.getAsyncJob(jobId)`)\n * @param jobId The ID of the async job to fetch\n * @param request Optional OystehrClientRequest for authentication and headers\n * @returns A Promise that resolves to the FhirAsyncJobStatus\n */\n getAsyncJob = ext.getAsyncJob;\n /**\n * Waits for an async job to complete by polling its status until it reaches a terminal state (success, failure, or expiration) or the specified timeout is reached. Returns the final job status. Throws if the job fails, expires, or does not complete within the timeout.\n * @param this The SDKResource context (this is an extension method and should be called with the SDKResource instance as the context, e.g. `sdkResource.waitForAsyncJob(jobId)`)\n * @param jobId The ID of the async job to wait for\n * @param options Optional FhirAsyncWaitOptions to configure polling behavior\n * @param request Optional OystehrClientRequest for authentication and headers\n * @returns A Promise that resolves to the final FhirAsyncJobStatus\n */\n waitForAsyncJob = ext.waitForAsyncJob;\n /**\n * Waits for an async job to complete and retrieves the bulk output manifest and files. Throws if the job fails, expires, or does not complete within the specified timeout.\n * @param this The SDKResource context (this is an extension method and should be called with the SDKResource instance as the context, e.g. `sdkResource.waitForAsyncBulkOutput(jobId)`)\n * @param jobId The ID of the async job to wait for\n * @param options Optional FhirAsyncWaitOptions to configure polling behavior\n * @param request Optional OystehrClientRequest for authentication and headers\n * @returns A Promise that resolves to a FhirAsyncBulkOutputResult containing the bulk output manifest and files\n */\n waitForAsyncBulkOutput = ext.waitForAsyncBulkOutput;\n /**\n * Wrapper around waitForAsyncBulkOutput that transforms the retrieved bulk output files into a single Bundle resource containing all the output resources as entries. This is a convenience method for use cases where you want to work with the bulk output as a Bundle, but it may not be efficient for large outputs due to the overhead of downloading and parsing all files and constructing the Bundle in memory.\n * Can be slow due to downloading and parsing potentially large NDJSON files, so use only if you need the full output as a Bundle resource. For more efficient processing of large bulk outputs, use waitForAsyncBulkOutput directly.\n * @param jobId the ID of the async job to wait for\n * @param options optional FhirAsyncWaitOptions to configure polling behavior\n * @param request optional OystehrClientRequest for authentication and headers\n * @returns a Promise that resolves to a Bundle containing all resources from the bulk output\n */\n waitForAsyncBulkBundle = ext.waitForAsyncBulkBundle;\n cancelAsyncJob = ext.cancelAsyncJob;\n history = ext.history;\n batch = ext.batch;\n transaction = ext.transaction;\n generateFriendlyPatientId = ext.generateFriendlyPatientId;\n formatAddress = ext.formatAddress;\n formatHumanName = ext.formatHumanName;\n}\n"],"names":["ext.search","ext.searchAndGetAllPages","ext.create","ext.get","ext.update","ext.patch","ext.delete","ext.getAsyncJob","ext.waitForAsyncJob","ext.waitForAsyncBulkOutput","ext.waitForAsyncBulkBundle","ext.cancelAsyncJob","ext.history","ext.batch","ext.transaction","ext.generateFriendlyPatientId","ext.formatAddress","ext.formatHumanName"],"mappings":";;;AAAA;AAMM,MAAO,IAAK,SAAQ,WAAW,CAAA;AACnC,IAAA,WAAA,CAAY,MAAqB,EAAA;QAC/B,KAAK,CAAC,MAAM,CAAC;IACf;IACA,aAAa,GAAA;QACX,OAAO,IAAI,CAAC,MAAM,CAAC,QAAQ,GAAG,YAAY,CAAC,IAAI,6BAA6B;IAC9E;AACA;;;;;AAKG;AACH,IAAA,MAAM,GAAGA,MAAU;AACnB;;;;;;;AAOG;AACH,IAAA,oBAAoB,GAAGC,oBAAwB;AAC/C,IAAA,MAAM,GAAGC,MAAU;AACnB,IAAA,GAAG,GAAGC,GAAO;AACb,IAAA,MAAM,GAAGC,MAAU;AACnB,IAAA,KAAK,GAAGC,KAAS;AACjB,IAAA,MAAM,GAAGC,GAAU;AACnB;;;;;;AAMG;AACH,IAAA,WAAW,GAAGC,WAAe;AAC7B;;;;;;;AAOG;AACH,IAAA,eAAe,GAAGC,eAAmB;AACrC;;;;;;;AAOG;AACH,IAAA,sBAAsB,GAAGC,sBAA0B;AACnD;;;;;;;AAOG;AACH,IAAA,sBAAsB,GAAGC,sBAA0B;AACnD,IAAA,cAAc,GAAGC,cAAkB;AACnC,IAAA,OAAO,GAAGC,OAAW;AACrB,IAAA,KAAK,GAAGC,KAAS;AACjB,IAAA,WAAW,GAAGC,WAAe;AAC7B,IAAA,yBAAyB,GAAGC,yBAA6B;AACzD,IAAA,aAAa,GAAGC,aAAiB;AACjC,IAAA,eAAe,GAAGC,eAAmB;AACtC;;;;"}
@@ -1,4 +1,4 @@
1
- import { OystehrClientRequest, RcmEligibilityCheckParams, RcmEligibilityCheckResponse, RcmGetPayerParams, RcmGetPayerResponse, RcmListPayersParams, RcmListPayersResponse, RcmSetClaimStatusParams, RcmSetClaimStatusResponse, RcmSubmitClaimParams, RcmSubmitClaimResponse } from '../..';
1
+ import { OystehrClientRequest, RcmEligibilityCheckParams, RcmEligibilityCheckResponse, RcmGetPayerParams, RcmGetPayerResponse, RcmListPayersParams, RcmListPayersResponse, RcmProcessEraParams, RcmProcessEraResponse, RcmSetClaimStatusParams, RcmSetClaimStatusResponse, RcmSubmitClaimParams, RcmSubmitClaimResponse } from '../..';
2
2
  import { SDKResource } from '../../client/client';
3
3
  import { OystehrConfig } from '../../config';
4
4
  import * as ext from './rcm-ext';
@@ -58,4 +58,11 @@ export declare class Rcm extends SDKResource {
58
58
  * Access Policy Resource: `RCM:Payer`
59
59
  */
60
60
  getPayer(params: RcmGetPayerParams, request?: OystehrClientRequest): Promise<RcmGetPayerResponse>;
61
+ /**
62
+ * Allows to manually process EDI835.
63
+ *
64
+ * Access Policy Action: `RCM:ProcessEra`
65
+ * Access Policy Resource: `RCM:Era`
66
+ */
67
+ processEra(params: RcmProcessEraParams, request?: OystehrClientRequest): Promise<RcmProcessEraResponse>;
61
68
  }
@@ -65,6 +65,15 @@ class Rcm extends SDKResource {
65
65
  getPayer(params, request) {
66
66
  return this.request('/payer/{id}', 'get', this.#baseUrlThunk.bind(this))(params, request);
67
67
  }
68
+ /**
69
+ * Allows to manually process EDI835.
70
+ *
71
+ * Access Policy Action: `RCM:ProcessEra`
72
+ * Access Policy Resource: `RCM:Era`
73
+ */
74
+ processEra(params, request) {
75
+ return this.request('/process-era', 'post', this.#baseUrlThunk.bind(this))(params, request);
76
+ }
68
77
  }
69
78
 
70
79
  export { Rcm };
@@ -1 +1 @@
1
- {"version":3,"file":"rcm.js","sources":["../../../../src/resources/classes/rcm.ts"],"sourcesContent":["// AUTOGENERATED -- DO NOT EDIT\n\nimport {\n OystehrClientRequest,\n RcmEligibilityCheckParams,\n RcmEligibilityCheckResponse,\n RcmGetPayerParams,\n RcmGetPayerResponse,\n RcmListPayersParams,\n RcmListPayersResponse,\n RcmSetClaimStatusParams,\n RcmSetClaimStatusResponse,\n RcmSubmitClaimParams,\n RcmSubmitClaimResponse,\n} from '../..';\nimport { SDKResource } from '../../client/client';\nimport { OystehrConfig } from '../../config';\nimport * as ext from './rcm-ext';\n\nexport class Rcm extends SDKResource {\n constructor(config: OystehrConfig) {\n super(config);\n }\n #baseUrlThunk(): string {\n return this.config.services?.['rcmApiUrl'] ?? 'https://rcm-api.zapehr.com/v1';\n }\n constructPayerUrl = ext.constructPayerUrl;\n getPayerByUrl = ext.getPayerByUrl;\n /**\n * Check [Insurance Eligibility](https://docs.oystehr.com/oystehr/services/rcm/eligibility/).\n *\n * Access Policy Action: `RCM:CheckInsuranceEligibility`\n * Access Policy Resource: `RCM:InsuranceEligibility`\n *\n * Access Policy Action: `FHIR:Create`\n * Access Policy Resource: `FHIR:CoverageEligibilityResponse`\n */\n eligibilityCheck(\n params: RcmEligibilityCheckParams,\n request?: OystehrClientRequest\n ): Promise<RcmEligibilityCheckResponse> {\n return this.request('/eligibility-check', 'post', this.#baseUrlThunk.bind(this))(params, request);\n }\n /**\n * Submit a claim to a payer.\n *\n * Access Policy Action: `RCM:SubmitClaim`\n * Access Policy Resource: `RCM:Claim`\n *\n * Access Policy Action: `FHIR:Create`\n * Access Policy Resource: `FHIR:ClaimResponse`\n */\n submitClaim(params: RcmSubmitClaimParams, request?: OystehrClientRequest): Promise<RcmSubmitClaimResponse> {\n return this.request('/claim/{claimId}/submit', 'post', this.#baseUrlThunk.bind(this))(params, request);\n }\n /**\n * Emulate asynchronous claim responses by manually setting claim status.\n *\n * Access Policy Action: `RCM:SubmitClaim`\n * Access Policy Resource: `RCM:Claim`\n *\n * Access Policy Action: `FHIR:Create`\n * Access Policy Resource: `FHIR:ClaimResponse`\n */\n setClaimStatus(params: RcmSetClaimStatusParams, request?: OystehrClientRequest): Promise<RcmSetClaimStatusResponse> {\n return this.request('/claim/{claimId}/status', 'post', this.#baseUrlThunk.bind(this))(params, request);\n }\n /**\n * Search for payers by name or identifier.\n *\n * Access Policy Action: `RCM:SearchPayer`\n * Access Policy Resource: `RCM:Payer`\n */\n listPayers(params: RcmListPayersParams, request?: OystehrClientRequest): Promise<RcmListPayersResponse>;\n /**\n * Search for payers by name or identifier.\n *\n * Access Policy Action: `RCM:SearchPayer`\n * Access Policy Resource: `RCM:Payer`\n */\n listPayers(request?: OystehrClientRequest): Promise<RcmListPayersResponse>;\n /**\n * Search for payers by name or identifier.\n *\n * Access Policy Action: `RCM:SearchPayer`\n * Access Policy Resource: `RCM:Payer`\n */\n listPayers(\n params?: RcmListPayersParams | OystehrClientRequest,\n request?: OystehrClientRequest\n ): Promise<RcmListPayersResponse> {\n return this.request('/payer', 'get', this.#baseUrlThunk.bind(this))(params, request);\n }\n /**\n * Retrieve a payer by its ID.\n *\n * Access Policy Action: `RCM:GetPayer`\n * Access Policy Resource: `RCM:Payer`\n */\n getPayer(params: RcmGetPayerParams, request?: OystehrClientRequest): Promise<RcmGetPayerResponse> {\n return this.request('/payer/{id}', 'get', this.#baseUrlThunk.bind(this))(params, request);\n }\n}\n"],"names":["ext.constructPayerUrl","ext.getPayerByUrl"],"mappings":";;;AAAA;AAmBM,MAAO,GAAI,SAAQ,WAAW,CAAA;AAClC,IAAA,WAAA,CAAY,MAAqB,EAAA;QAC/B,KAAK,CAAC,MAAM,CAAC;IACf;IACA,aAAa,GAAA;QACX,OAAO,IAAI,CAAC,MAAM,CAAC,QAAQ,GAAG,WAAW,CAAC,IAAI,+BAA+B;IAC/E;AACA,IAAA,iBAAiB,GAAGA,iBAAqB;AACzC,IAAA,aAAa,GAAGC,aAAiB;AACjC;;;;;;;;AAQG;IACH,gBAAgB,CACd,MAAiC,EACjC,OAA8B,EAAA;QAE9B,OAAO,IAAI,CAAC,OAAO,CAAC,oBAAoB,EAAE,MAAM,EAAE,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC,MAAM,EAAE,OAAO,CAAC;IACnG;AACA;;;;;;;;AAQG;IACH,WAAW,CAAC,MAA4B,EAAE,OAA8B,EAAA;QACtE,OAAO,IAAI,CAAC,OAAO,CAAC,yBAAyB,EAAE,MAAM,EAAE,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC,MAAM,EAAE,OAAO,CAAC;IACxG;AACA;;;;;;;;AAQG;IACH,cAAc,CAAC,MAA+B,EAAE,OAA8B,EAAA;QAC5E,OAAO,IAAI,CAAC,OAAO,CAAC,yBAAyB,EAAE,MAAM,EAAE,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC,MAAM,EAAE,OAAO,CAAC;IACxG;AAeA;;;;;AAKG;IACH,UAAU,CACR,MAAmD,EACnD,OAA8B,EAAA;QAE9B,OAAO,IAAI,CAAC,OAAO,CAAC,QAAQ,EAAE,KAAK,EAAE,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC,MAAM,EAAE,OAAO,CAAC;IACtF;AACA;;;;;AAKG;IACH,QAAQ,CAAC,MAAyB,EAAE,OAA8B,EAAA;QAChE,OAAO,IAAI,CAAC,OAAO,CAAC,aAAa,EAAE,KAAK,EAAE,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC,MAAM,EAAE,OAAO,CAAC;IAC3F;AACD;;;;"}
1
+ {"version":3,"file":"rcm.js","sources":["../../../../src/resources/classes/rcm.ts"],"sourcesContent":["// AUTOGENERATED -- DO NOT EDIT\n\nimport {\n OystehrClientRequest,\n RcmEligibilityCheckParams,\n RcmEligibilityCheckResponse,\n RcmGetPayerParams,\n RcmGetPayerResponse,\n RcmListPayersParams,\n RcmListPayersResponse,\n RcmProcessEraParams,\n RcmProcessEraResponse,\n RcmSetClaimStatusParams,\n RcmSetClaimStatusResponse,\n RcmSubmitClaimParams,\n RcmSubmitClaimResponse,\n} from '../..';\nimport { SDKResource } from '../../client/client';\nimport { OystehrConfig } from '../../config';\nimport * as ext from './rcm-ext';\n\nexport class Rcm extends SDKResource {\n constructor(config: OystehrConfig) {\n super(config);\n }\n #baseUrlThunk(): string {\n return this.config.services?.['rcmApiUrl'] ?? 'https://rcm-api.zapehr.com/v1';\n }\n constructPayerUrl = ext.constructPayerUrl;\n getPayerByUrl = ext.getPayerByUrl;\n /**\n * Check [Insurance Eligibility](https://docs.oystehr.com/oystehr/services/rcm/eligibility/).\n *\n * Access Policy Action: `RCM:CheckInsuranceEligibility`\n * Access Policy Resource: `RCM:InsuranceEligibility`\n *\n * Access Policy Action: `FHIR:Create`\n * Access Policy Resource: `FHIR:CoverageEligibilityResponse`\n */\n eligibilityCheck(\n params: RcmEligibilityCheckParams,\n request?: OystehrClientRequest\n ): Promise<RcmEligibilityCheckResponse> {\n return this.request('/eligibility-check', 'post', this.#baseUrlThunk.bind(this))(params, request);\n }\n /**\n * Submit a claim to a payer.\n *\n * Access Policy Action: `RCM:SubmitClaim`\n * Access Policy Resource: `RCM:Claim`\n *\n * Access Policy Action: `FHIR:Create`\n * Access Policy Resource: `FHIR:ClaimResponse`\n */\n submitClaim(params: RcmSubmitClaimParams, request?: OystehrClientRequest): Promise<RcmSubmitClaimResponse> {\n return this.request('/claim/{claimId}/submit', 'post', this.#baseUrlThunk.bind(this))(params, request);\n }\n /**\n * Emulate asynchronous claim responses by manually setting claim status.\n *\n * Access Policy Action: `RCM:SubmitClaim`\n * Access Policy Resource: `RCM:Claim`\n *\n * Access Policy Action: `FHIR:Create`\n * Access Policy Resource: `FHIR:ClaimResponse`\n */\n setClaimStatus(params: RcmSetClaimStatusParams, request?: OystehrClientRequest): Promise<RcmSetClaimStatusResponse> {\n return this.request('/claim/{claimId}/status', 'post', this.#baseUrlThunk.bind(this))(params, request);\n }\n /**\n * Search for payers by name or identifier.\n *\n * Access Policy Action: `RCM:SearchPayer`\n * Access Policy Resource: `RCM:Payer`\n */\n listPayers(params: RcmListPayersParams, request?: OystehrClientRequest): Promise<RcmListPayersResponse>;\n /**\n * Search for payers by name or identifier.\n *\n * Access Policy Action: `RCM:SearchPayer`\n * Access Policy Resource: `RCM:Payer`\n */\n listPayers(request?: OystehrClientRequest): Promise<RcmListPayersResponse>;\n /**\n * Search for payers by name or identifier.\n *\n * Access Policy Action: `RCM:SearchPayer`\n * Access Policy Resource: `RCM:Payer`\n */\n listPayers(\n params?: RcmListPayersParams | OystehrClientRequest,\n request?: OystehrClientRequest\n ): Promise<RcmListPayersResponse> {\n return this.request('/payer', 'get', this.#baseUrlThunk.bind(this))(params, request);\n }\n /**\n * Retrieve a payer by its ID.\n *\n * Access Policy Action: `RCM:GetPayer`\n * Access Policy Resource: `RCM:Payer`\n */\n getPayer(params: RcmGetPayerParams, request?: OystehrClientRequest): Promise<RcmGetPayerResponse> {\n return this.request('/payer/{id}', 'get', this.#baseUrlThunk.bind(this))(params, request);\n }\n /**\n * Allows to manually process EDI835.\n *\n * Access Policy Action: `RCM:ProcessEra`\n * Access Policy Resource: `RCM:Era`\n */\n processEra(params: RcmProcessEraParams, request?: OystehrClientRequest): Promise<RcmProcessEraResponse> {\n return this.request('/process-era', 'post', this.#baseUrlThunk.bind(this))(params, request);\n }\n}\n"],"names":["ext.constructPayerUrl","ext.getPayerByUrl"],"mappings":";;;AAAA;AAqBM,MAAO,GAAI,SAAQ,WAAW,CAAA;AAClC,IAAA,WAAA,CAAY,MAAqB,EAAA;QAC/B,KAAK,CAAC,MAAM,CAAC;IACf;IACA,aAAa,GAAA;QACX,OAAO,IAAI,CAAC,MAAM,CAAC,QAAQ,GAAG,WAAW,CAAC,IAAI,+BAA+B;IAC/E;AACA,IAAA,iBAAiB,GAAGA,iBAAqB;AACzC,IAAA,aAAa,GAAGC,aAAiB;AACjC;;;;;;;;AAQG;IACH,gBAAgB,CACd,MAAiC,EACjC,OAA8B,EAAA;QAE9B,OAAO,IAAI,CAAC,OAAO,CAAC,oBAAoB,EAAE,MAAM,EAAE,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC,MAAM,EAAE,OAAO,CAAC;IACnG;AACA;;;;;;;;AAQG;IACH,WAAW,CAAC,MAA4B,EAAE,OAA8B,EAAA;QACtE,OAAO,IAAI,CAAC,OAAO,CAAC,yBAAyB,EAAE,MAAM,EAAE,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC,MAAM,EAAE,OAAO,CAAC;IACxG;AACA;;;;;;;;AAQG;IACH,cAAc,CAAC,MAA+B,EAAE,OAA8B,EAAA;QAC5E,OAAO,IAAI,CAAC,OAAO,CAAC,yBAAyB,EAAE,MAAM,EAAE,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC,MAAM,EAAE,OAAO,CAAC;IACxG;AAeA;;;;;AAKG;IACH,UAAU,CACR,MAAmD,EACnD,OAA8B,EAAA;QAE9B,OAAO,IAAI,CAAC,OAAO,CAAC,QAAQ,EAAE,KAAK,EAAE,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC,MAAM,EAAE,OAAO,CAAC;IACtF;AACA;;;;;AAKG;IACH,QAAQ,CAAC,MAAyB,EAAE,OAA8B,EAAA;QAChE,OAAO,IAAI,CAAC,OAAO,CAAC,aAAa,EAAE,KAAK,EAAE,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC,MAAM,EAAE,OAAO,CAAC;IAC3F;AACA;;;;;AAKG;IACH,UAAU,CAAC,MAA2B,EAAE,OAA8B,EAAA;QACpE,OAAO,IAAI,CAAC,OAAO,CAAC,cAAc,EAAE,MAAM,EAAE,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC,MAAM,EAAE,OAAO,CAAC;IAC7F;AACD;;;;"}
@@ -1,4 +1,4 @@
1
- import { OystehrClientRequest, TerminologySearchCptParams, TerminologySearchCptResponse, TerminologySearchHcpcsParams, TerminologySearchHcpcsResponse } from '../..';
1
+ import { OystehrClientRequest, TerminologySearchCptParams, TerminologySearchCptResponse, TerminologySearchHcpcsParams, TerminologySearchHcpcsResponse, TerminologySearchIcd10Params, TerminologySearchIcd10Response } from '../..';
2
2
  import { SDKResource } from '../../client/client';
3
3
  import { OystehrConfig } from '../../config';
4
4
  export declare class Terminology extends SDKResource {
@@ -18,4 +18,11 @@ export declare class Terminology extends SDKResource {
18
18
  * Access Policy Resource: `Terminology:Code:*`
19
19
  */
20
20
  searchHcpcs(params: TerminologySearchHcpcsParams, request?: OystehrClientRequest): Promise<TerminologySearchHcpcsResponse>;
21
+ /**
22
+ * Search ICD-10-CM (International Classification of Diseases, 10th Revision, Clinical Modification) diagnosis codes by code or description. Only billable (leaf-node) codes are returned, including codes expanded with their required seventh character. Supports exact matches, prefix searches, and full-text search with BM25 ranking.
23
+ *
24
+ * Access Policy Action: `Terminology:SearchCodes`
25
+ * Access Policy Resource: `Terminology:Code:*`
26
+ */
27
+ searchIcd10(params: TerminologySearchIcd10Params, request?: OystehrClientRequest): Promise<TerminologySearchIcd10Response>;
21
28
  }
@@ -26,6 +26,15 @@ class Terminology extends SDKResource {
26
26
  searchHcpcs(params, request) {
27
27
  return this.request('/hcpcs/search', 'get', this.#baseUrlThunk.bind(this))(params, request);
28
28
  }
29
+ /**
30
+ * Search ICD-10-CM (International Classification of Diseases, 10th Revision, Clinical Modification) diagnosis codes by code or description. Only billable (leaf-node) codes are returned, including codes expanded with their required seventh character. Supports exact matches, prefix searches, and full-text search with BM25 ranking.
31
+ *
32
+ * Access Policy Action: `Terminology:SearchCodes`
33
+ * Access Policy Resource: `Terminology:Code:*`
34
+ */
35
+ searchIcd10(params, request) {
36
+ return this.request('/icd10/search', 'get', this.#baseUrlThunk.bind(this))(params, request);
37
+ }
29
38
  }
30
39
 
31
40
  export { Terminology };
@@ -1 +1 @@
1
- {"version":3,"file":"terminology.js","sources":["../../../../src/resources/classes/terminology.ts"],"sourcesContent":["// AUTOGENERATED -- DO NOT EDIT\n\nimport {\n OystehrClientRequest,\n TerminologySearchCptParams,\n TerminologySearchCptResponse,\n TerminologySearchHcpcsParams,\n TerminologySearchHcpcsResponse,\n} from '../..';\nimport { SDKResource } from '../../client/client';\nimport { OystehrConfig } from '../../config';\n\nexport class Terminology extends SDKResource {\n constructor(config: OystehrConfig) {\n super(config);\n }\n #baseUrlThunk(): string {\n return this.config.services?.['terminologyApiUrl'] ?? 'https://terminology-api.zapehr.com/v1';\n }\n /**\n * Search CPT (Current Procedural Terminology) codes by code or description. Supports exact matches, prefix searches, and full-text search with BM25 ranking.\n *\n * Access Policy Action: `Terminology:SearchCodes`\n * Access Policy Resource: `Terminology:Code:*`\n */\n searchCpt(params: TerminologySearchCptParams, request?: OystehrClientRequest): Promise<TerminologySearchCptResponse> {\n return this.request('/cpt/search', 'get', this.#baseUrlThunk.bind(this))(params, request);\n }\n /**\n * Search HCPCS (Healthcare Common Procedure Coding System) Level II codes by code or description. Supports exact matches, prefix searches, and full-text search with BM25 ranking.\n *\n * Access Policy Action: `Terminology:SearchCodes`\n * Access Policy Resource: `Terminology:Code:*`\n */\n searchHcpcs(\n params: TerminologySearchHcpcsParams,\n request?: OystehrClientRequest\n ): Promise<TerminologySearchHcpcsResponse> {\n return this.request('/hcpcs/search', 'get', this.#baseUrlThunk.bind(this))(params, request);\n }\n}\n"],"names":[],"mappings":";;AAAA;AAYM,MAAO,WAAY,SAAQ,WAAW,CAAA;AAC1C,IAAA,WAAA,CAAY,MAAqB,EAAA;QAC/B,KAAK,CAAC,MAAM,CAAC;IACf;IACA,aAAa,GAAA;QACX,OAAO,IAAI,CAAC,MAAM,CAAC,QAAQ,GAAG,mBAAmB,CAAC,IAAI,uCAAuC;IAC/F;AACA;;;;;AAKG;IACH,SAAS,CAAC,MAAkC,EAAE,OAA8B,EAAA;QAC1E,OAAO,IAAI,CAAC,OAAO,CAAC,aAAa,EAAE,KAAK,EAAE,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC,MAAM,EAAE,OAAO,CAAC;IAC3F;AACA;;;;;AAKG;IACH,WAAW,CACT,MAAoC,EACpC,OAA8B,EAAA;QAE9B,OAAO,IAAI,CAAC,OAAO,CAAC,eAAe,EAAE,KAAK,EAAE,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC,MAAM,EAAE,OAAO,CAAC;IAC7F;AACD;;;;"}
1
+ {"version":3,"file":"terminology.js","sources":["../../../../src/resources/classes/terminology.ts"],"sourcesContent":["// AUTOGENERATED -- DO NOT EDIT\n\nimport {\n OystehrClientRequest,\n TerminologySearchCptParams,\n TerminologySearchCptResponse,\n TerminologySearchHcpcsParams,\n TerminologySearchHcpcsResponse,\n TerminologySearchIcd10Params,\n TerminologySearchIcd10Response,\n} from '../..';\nimport { SDKResource } from '../../client/client';\nimport { OystehrConfig } from '../../config';\n\nexport class Terminology extends SDKResource {\n constructor(config: OystehrConfig) {\n super(config);\n }\n #baseUrlThunk(): string {\n return this.config.services?.['terminologyApiUrl'] ?? 'https://terminology-api.zapehr.com/v1';\n }\n /**\n * Search CPT (Current Procedural Terminology) codes by code or description. Supports exact matches, prefix searches, and full-text search with BM25 ranking.\n *\n * Access Policy Action: `Terminology:SearchCodes`\n * Access Policy Resource: `Terminology:Code:*`\n */\n searchCpt(params: TerminologySearchCptParams, request?: OystehrClientRequest): Promise<TerminologySearchCptResponse> {\n return this.request('/cpt/search', 'get', this.#baseUrlThunk.bind(this))(params, request);\n }\n /**\n * Search HCPCS (Healthcare Common Procedure Coding System) Level II codes by code or description. Supports exact matches, prefix searches, and full-text search with BM25 ranking.\n *\n * Access Policy Action: `Terminology:SearchCodes`\n * Access Policy Resource: `Terminology:Code:*`\n */\n searchHcpcs(\n params: TerminologySearchHcpcsParams,\n request?: OystehrClientRequest\n ): Promise<TerminologySearchHcpcsResponse> {\n return this.request('/hcpcs/search', 'get', this.#baseUrlThunk.bind(this))(params, request);\n }\n /**\n * Search ICD-10-CM (International Classification of Diseases, 10th Revision, Clinical Modification) diagnosis codes by code or description. Only billable (leaf-node) codes are returned, including codes expanded with their required seventh character. Supports exact matches, prefix searches, and full-text search with BM25 ranking.\n *\n * Access Policy Action: `Terminology:SearchCodes`\n * Access Policy Resource: `Terminology:Code:*`\n */\n searchIcd10(\n params: TerminologySearchIcd10Params,\n request?: OystehrClientRequest\n ): Promise<TerminologySearchIcd10Response> {\n return this.request('/icd10/search', 'get', this.#baseUrlThunk.bind(this))(params, request);\n }\n}\n"],"names":[],"mappings":";;AAAA;AAcM,MAAO,WAAY,SAAQ,WAAW,CAAA;AAC1C,IAAA,WAAA,CAAY,MAAqB,EAAA;QAC/B,KAAK,CAAC,MAAM,CAAC;IACf;IACA,aAAa,GAAA;QACX,OAAO,IAAI,CAAC,MAAM,CAAC,QAAQ,GAAG,mBAAmB,CAAC,IAAI,uCAAuC;IAC/F;AACA;;;;;AAKG;IACH,SAAS,CAAC,MAAkC,EAAE,OAA8B,EAAA;QAC1E,OAAO,IAAI,CAAC,OAAO,CAAC,aAAa,EAAE,KAAK,EAAE,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC,MAAM,EAAE,OAAO,CAAC;IAC3F;AACA;;;;;AAKG;IACH,WAAW,CACT,MAAoC,EACpC,OAA8B,EAAA;QAE9B,OAAO,IAAI,CAAC,OAAO,CAAC,eAAe,EAAE,KAAK,EAAE,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC,MAAM,EAAE,OAAO,CAAC;IAC7F;AACA;;;;;AAKG;IACH,WAAW,CACT,MAAoC,EACpC,OAA8B,EAAA;QAE9B,OAAO,IAAI,CAAC,OAAO,CAAC,eAAe,EAAE,KAAK,EAAE,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC,MAAM,EAAE,OAAO,CAAC;IAC7F;AACD;;;;"}
@@ -1,4 +1,4 @@
1
- import { OystehrClientRequest, Z3CreateBucketParams, Z3CreateBucketResponse, Z3DeleteBucketParams, Z3DeleteObjectParams, Z3GetPresignedUrlParams, Z3GetPresignedUrlResponse, Z3ListBucketsResponse, Z3ListObjectsParams, Z3ListObjectsResponse } from '../..';
1
+ import { OystehrClientRequest, Z3CreateBucketParams, Z3CreateBucketResponse, Z3DeleteBucketParams, Z3DeleteObjectParams, Z3EmptyBucketParams, Z3EmptyBucketResponse, Z3GetPresignedUrlParams, Z3GetPresignedUrlResponse, Z3ListBucketsResponse, Z3ListObjectsParams, Z3ListObjectsResponse } from '../..';
2
2
  import { SDKResource } from '../../client/client';
3
3
  import { OystehrConfig } from '../../config';
4
4
  import * as ext from './z3-ext';
@@ -43,6 +43,13 @@ export declare class Z3 extends SDKResource {
43
43
  * Access Policy Resource: `Z3:BucketName`
44
44
  */
45
45
  deleteBucket(params: Z3DeleteBucketParams, request?: OystehrClientRequest): Promise<void>;
46
+ /**
47
+ * Recursively delete all Z3 Objects in the Bucket with the provided name. [Z3](https://docs.oystehr.com/oystehr/services/z3/) is Oystehr's built-in and fully integrated solution for file storage.
48
+ *
49
+ * Access Policy Action: `Z3:EmptyBucket`
50
+ * Access Policy Resource: `Z3:BucketName`
51
+ */
52
+ emptyBucket(params: Z3EmptyBucketParams, request?: OystehrClientRequest): Promise<Z3EmptyBucketResponse>;
46
53
  /**
47
54
  * List all Z3 Objects at the provided path in the Bucket with the provided name [Z3](https://docs.oystehr.com/oystehr/services/z3/) is Oystehr's built-in and fully integrated solution for file storage.
48
55
  *
@@ -53,6 +53,15 @@ class Z3 extends SDKResource {
53
53
  deleteBucket(params, request) {
54
54
  return this.request('/z3/{bucketName}', 'delete', this.#baseUrlThunk.bind(this))(params, request);
55
55
  }
56
+ /**
57
+ * Recursively delete all Z3 Objects in the Bucket with the provided name. [Z3](https://docs.oystehr.com/oystehr/services/z3/) is Oystehr's built-in and fully integrated solution for file storage.
58
+ *
59
+ * Access Policy Action: `Z3:EmptyBucket`
60
+ * Access Policy Resource: `Z3:BucketName`
61
+ */
62
+ emptyBucket(params, request) {
63
+ return this.request('/z3/{bucketName}/objects', 'delete', this.#baseUrlThunk.bind(this))(params, request);
64
+ }
56
65
  /**
57
66
  * List all Z3 Objects at the provided path in the Bucket with the provided name [Z3](https://docs.oystehr.com/oystehr/services/z3/) is Oystehr's built-in and fully integrated solution for file storage.
58
67
  *
@@ -1 +1 @@
1
- {"version":3,"file":"z3.js","sources":["../../../../src/resources/classes/z3.ts"],"sourcesContent":["// AUTOGENERATED -- DO NOT EDIT\n\nimport {\n OystehrClientRequest,\n Z3CreateBucketParams,\n Z3CreateBucketResponse,\n Z3DeleteBucketParams,\n Z3DeleteObjectParams,\n Z3GetPresignedUrlParams,\n Z3GetPresignedUrlResponse,\n Z3ListBucketsResponse,\n Z3ListObjectsParams,\n Z3ListObjectsResponse,\n} from '../..';\nimport { SDKResource } from '../../client/client';\nimport { OystehrConfig } from '../../config';\nimport * as ext from './z3-ext';\n\nexport class Z3 extends SDKResource {\n constructor(config: OystehrConfig) {\n super(config);\n }\n #baseUrlThunk(): string {\n return this.config.services?.['projectApiUrl'] ?? 'https://project-api.zapehr.com/v1';\n }\n /**\n * Uploads a file to the bucket and key. Files should be Blobs.\n * @param params upload file params\n */\n uploadFile = ext.uploadFile;\n /**\n * Downloads an object matching the bucket and key. File content is returned as an ArrayBuffer.\n * @param params download file params\n */\n downloadFile = ext.downloadFile;\n /**\n * This helper performs a `getPresignedUrl` request for Z3 URLs of the forms\n * `https://projects-api.oystehr.com/v1/z3/<bucket>/<key>` or `z3://<bucket>/<key>`\n * instead of the standard SDK `Z3GetPresignedUrlParams`.\n * @param params url and action\n */\n getPresignedUrlForZ3Url = ext.getPresignedUrlForZ3Url;\n /**\n * List all Z3 Buckets. [Z3](https://docs.oystehr.com/oystehr/services/z3/) is Oystehr's built-in and fully integrated solution for file storage.\n *\n * Access Policy Action: `Z3:ListBuckets`\n * Access Policy Resource: `Z3:BucketName`\n */\n listBuckets(request?: OystehrClientRequest): Promise<Z3ListBucketsResponse> {\n return this.request('/z3', 'get', this.#baseUrlThunk.bind(this))(request);\n }\n /**\n * Create a Z3 Bucket with the provided name. [Z3](https://docs.oystehr.com/oystehr/services/z3/) is Oystehr's built-in and fully integrated solution for file storage.\n *\n * Access Policy Action: `Z3:CreateBucket`\n * Access Policy Resource: `Z3:*`\n */\n createBucket(params: Z3CreateBucketParams, request?: OystehrClientRequest): Promise<Z3CreateBucketResponse> {\n return this.request('/z3/{bucketName}', 'put', this.#baseUrlThunk.bind(this))(params, request);\n }\n /**\n * Delete the Z3 Bucket with the provided name. [Z3](https://docs.oystehr.com/oystehr/services/z3/) is Oystehr's built-in and fully integrated solution for file storage.\n *\n * Access Policy Action: `Z3:DeleteBucket`\n * Access Policy Resource: `Z3:BucketName`\n */\n deleteBucket(params: Z3DeleteBucketParams, request?: OystehrClientRequest): Promise<void> {\n return this.request('/z3/{bucketName}', 'delete', this.#baseUrlThunk.bind(this))(params, request);\n }\n /**\n * List all Z3 Objects at the provided path in the Bucket with the provided name [Z3](https://docs.oystehr.com/oystehr/services/z3/) is Oystehr's built-in and fully integrated solution for file storage.\n *\n * Access Policy Action: `Z3:ListObjects`\n * Access Policy Resource: `Z3:BucketName:ObjectPath`\n */\n listObjects(params: Z3ListObjectsParams, request?: OystehrClientRequest): Promise<Z3ListObjectsResponse> {\n return this.request('/z3/{bucketName}/{objectPath+}', 'get', this.#baseUrlThunk.bind(this))(params, request);\n }\n /**\n * Get a link for downloading or uploading a Z3 Object to the provided path in the Bucket with the provided name. [Z3](https://docs.oystehr.com/oystehr/services/z3/) is Oystehr's built-in and fully integrated solution for file storage.\n *\n * Access Policy Action: `Z3:PutObject` or `Z3:GetObject`\n * Access Policy Resource: `Z3:BucketName:ObjectPath`\n */\n getPresignedUrl(params: Z3GetPresignedUrlParams, request?: OystehrClientRequest): Promise<Z3GetPresignedUrlResponse> {\n return this.request('/z3/{bucketName}/{objectPath+}', 'post', this.#baseUrlThunk.bind(this))(params, request);\n }\n /**\n * Delete the Z3 Object at the provided path in the Bucket with the provided name. [Z3](https://docs.oystehr.com/oystehr/services/z3/) is Oystehr's built-in and fully integrated solution for file storage.\n *\n * Access Policy Action: `Z3:DeleteObject`\n * Access Policy Resource: `Z3:BucketName:ObjectPath`\n */\n deleteObject(params: Z3DeleteObjectParams, request?: OystehrClientRequest): Promise<void> {\n return this.request('/z3/{bucketName}/{objectPath+}', 'delete', this.#baseUrlThunk.bind(this))(params, request);\n }\n}\n"],"names":["ext.uploadFile","ext.downloadFile","ext.getPresignedUrlForZ3Url"],"mappings":";;;AAAA;AAkBM,MAAO,EAAG,SAAQ,WAAW,CAAA;AACjC,IAAA,WAAA,CAAY,MAAqB,EAAA;QAC/B,KAAK,CAAC,MAAM,CAAC;IACf;IACA,aAAa,GAAA;QACX,OAAO,IAAI,CAAC,MAAM,CAAC,QAAQ,GAAG,eAAe,CAAC,IAAI,mCAAmC;IACvF;AACA;;;AAGG;AACH,IAAA,UAAU,GAAGA,UAAc;AAC3B;;;AAGG;AACH,IAAA,YAAY,GAAGC,YAAgB;AAC/B;;;;;AAKG;AACH,IAAA,uBAAuB,GAAGC,uBAA2B;AACrD;;;;;AAKG;AACH,IAAA,WAAW,CAAC,OAA8B,EAAA;QACxC,OAAO,IAAI,CAAC,OAAO,CAAC,KAAK,EAAE,KAAK,EAAE,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC,OAAO,CAAC;IAC3E;AACA;;;;;AAKG;IACH,YAAY,CAAC,MAA4B,EAAE,OAA8B,EAAA;QACvE,OAAO,IAAI,CAAC,OAAO,CAAC,kBAAkB,EAAE,KAAK,EAAE,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC,MAAM,EAAE,OAAO,CAAC;IAChG;AACA;;;;;AAKG;IACH,YAAY,CAAC,MAA4B,EAAE,OAA8B,EAAA;QACvE,OAAO,IAAI,CAAC,OAAO,CAAC,kBAAkB,EAAE,QAAQ,EAAE,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC,MAAM,EAAE,OAAO,CAAC;IACnG;AACA;;;;;AAKG;IACH,WAAW,CAAC,MAA2B,EAAE,OAA8B,EAAA;QACrE,OAAO,IAAI,CAAC,OAAO,CAAC,gCAAgC,EAAE,KAAK,EAAE,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC,MAAM,EAAE,OAAO,CAAC;IAC9G;AACA;;;;;AAKG;IACH,eAAe,CAAC,MAA+B,EAAE,OAA8B,EAAA;QAC7E,OAAO,IAAI,CAAC,OAAO,CAAC,gCAAgC,EAAE,MAAM,EAAE,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC,MAAM,EAAE,OAAO,CAAC;IAC/G;AACA;;;;;AAKG;IACH,YAAY,CAAC,MAA4B,EAAE,OAA8B,EAAA;QACvE,OAAO,IAAI,CAAC,OAAO,CAAC,gCAAgC,EAAE,QAAQ,EAAE,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC,MAAM,EAAE,OAAO,CAAC;IACjH;AACD;;;;"}
1
+ {"version":3,"file":"z3.js","sources":["../../../../src/resources/classes/z3.ts"],"sourcesContent":["// AUTOGENERATED -- DO NOT EDIT\n\nimport {\n OystehrClientRequest,\n Z3CreateBucketParams,\n Z3CreateBucketResponse,\n Z3DeleteBucketParams,\n Z3DeleteObjectParams,\n Z3EmptyBucketParams,\n Z3EmptyBucketResponse,\n Z3GetPresignedUrlParams,\n Z3GetPresignedUrlResponse,\n Z3ListBucketsResponse,\n Z3ListObjectsParams,\n Z3ListObjectsResponse,\n} from '../..';\nimport { SDKResource } from '../../client/client';\nimport { OystehrConfig } from '../../config';\nimport * as ext from './z3-ext';\n\nexport class Z3 extends SDKResource {\n constructor(config: OystehrConfig) {\n super(config);\n }\n #baseUrlThunk(): string {\n return this.config.services?.['projectApiUrl'] ?? 'https://project-api.zapehr.com/v1';\n }\n /**\n * Uploads a file to the bucket and key. Files should be Blobs.\n * @param params upload file params\n */\n uploadFile = ext.uploadFile;\n /**\n * Downloads an object matching the bucket and key. File content is returned as an ArrayBuffer.\n * @param params download file params\n */\n downloadFile = ext.downloadFile;\n /**\n * This helper performs a `getPresignedUrl` request for Z3 URLs of the forms\n * `https://projects-api.oystehr.com/v1/z3/<bucket>/<key>` or `z3://<bucket>/<key>`\n * instead of the standard SDK `Z3GetPresignedUrlParams`.\n * @param params url and action\n */\n getPresignedUrlForZ3Url = ext.getPresignedUrlForZ3Url;\n /**\n * List all Z3 Buckets. [Z3](https://docs.oystehr.com/oystehr/services/z3/) is Oystehr's built-in and fully integrated solution for file storage.\n *\n * Access Policy Action: `Z3:ListBuckets`\n * Access Policy Resource: `Z3:BucketName`\n */\n listBuckets(request?: OystehrClientRequest): Promise<Z3ListBucketsResponse> {\n return this.request('/z3', 'get', this.#baseUrlThunk.bind(this))(request);\n }\n /**\n * Create a Z3 Bucket with the provided name. [Z3](https://docs.oystehr.com/oystehr/services/z3/) is Oystehr's built-in and fully integrated solution for file storage.\n *\n * Access Policy Action: `Z3:CreateBucket`\n * Access Policy Resource: `Z3:*`\n */\n createBucket(params: Z3CreateBucketParams, request?: OystehrClientRequest): Promise<Z3CreateBucketResponse> {\n return this.request('/z3/{bucketName}', 'put', this.#baseUrlThunk.bind(this))(params, request);\n }\n /**\n * Delete the Z3 Bucket with the provided name. [Z3](https://docs.oystehr.com/oystehr/services/z3/) is Oystehr's built-in and fully integrated solution for file storage.\n *\n * Access Policy Action: `Z3:DeleteBucket`\n * Access Policy Resource: `Z3:BucketName`\n */\n deleteBucket(params: Z3DeleteBucketParams, request?: OystehrClientRequest): Promise<void> {\n return this.request('/z3/{bucketName}', 'delete', this.#baseUrlThunk.bind(this))(params, request);\n }\n /**\n * Recursively delete all Z3 Objects in the Bucket with the provided name. [Z3](https://docs.oystehr.com/oystehr/services/z3/) is Oystehr's built-in and fully integrated solution for file storage.\n *\n * Access Policy Action: `Z3:EmptyBucket`\n * Access Policy Resource: `Z3:BucketName`\n */\n emptyBucket(params: Z3EmptyBucketParams, request?: OystehrClientRequest): Promise<Z3EmptyBucketResponse> {\n return this.request('/z3/{bucketName}/objects', 'delete', this.#baseUrlThunk.bind(this))(params, request);\n }\n /**\n * List all Z3 Objects at the provided path in the Bucket with the provided name [Z3](https://docs.oystehr.com/oystehr/services/z3/) is Oystehr's built-in and fully integrated solution for file storage.\n *\n * Access Policy Action: `Z3:ListObjects`\n * Access Policy Resource: `Z3:BucketName:ObjectPath`\n */\n listObjects(params: Z3ListObjectsParams, request?: OystehrClientRequest): Promise<Z3ListObjectsResponse> {\n return this.request('/z3/{bucketName}/{objectPath+}', 'get', this.#baseUrlThunk.bind(this))(params, request);\n }\n /**\n * Get a link for downloading or uploading a Z3 Object to the provided path in the Bucket with the provided name. [Z3](https://docs.oystehr.com/oystehr/services/z3/) is Oystehr's built-in and fully integrated solution for file storage.\n *\n * Access Policy Action: `Z3:PutObject` or `Z3:GetObject`\n * Access Policy Resource: `Z3:BucketName:ObjectPath`\n */\n getPresignedUrl(params: Z3GetPresignedUrlParams, request?: OystehrClientRequest): Promise<Z3GetPresignedUrlResponse> {\n return this.request('/z3/{bucketName}/{objectPath+}', 'post', this.#baseUrlThunk.bind(this))(params, request);\n }\n /**\n * Delete the Z3 Object at the provided path in the Bucket with the provided name. [Z3](https://docs.oystehr.com/oystehr/services/z3/) is Oystehr's built-in and fully integrated solution for file storage.\n *\n * Access Policy Action: `Z3:DeleteObject`\n * Access Policy Resource: `Z3:BucketName:ObjectPath`\n */\n deleteObject(params: Z3DeleteObjectParams, request?: OystehrClientRequest): Promise<void> {\n return this.request('/z3/{bucketName}/{objectPath+}', 'delete', this.#baseUrlThunk.bind(this))(params, request);\n }\n}\n"],"names":["ext.uploadFile","ext.downloadFile","ext.getPresignedUrlForZ3Url"],"mappings":";;;AAAA;AAoBM,MAAO,EAAG,SAAQ,WAAW,CAAA;AACjC,IAAA,WAAA,CAAY,MAAqB,EAAA;QAC/B,KAAK,CAAC,MAAM,CAAC;IACf;IACA,aAAa,GAAA;QACX,OAAO,IAAI,CAAC,MAAM,CAAC,QAAQ,GAAG,eAAe,CAAC,IAAI,mCAAmC;IACvF;AACA;;;AAGG;AACH,IAAA,UAAU,GAAGA,UAAc;AAC3B;;;AAGG;AACH,IAAA,YAAY,GAAGC,YAAgB;AAC/B;;;;;AAKG;AACH,IAAA,uBAAuB,GAAGC,uBAA2B;AACrD;;;;;AAKG;AACH,IAAA,WAAW,CAAC,OAA8B,EAAA;QACxC,OAAO,IAAI,CAAC,OAAO,CAAC,KAAK,EAAE,KAAK,EAAE,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC,OAAO,CAAC;IAC3E;AACA;;;;;AAKG;IACH,YAAY,CAAC,MAA4B,EAAE,OAA8B,EAAA;QACvE,OAAO,IAAI,CAAC,OAAO,CAAC,kBAAkB,EAAE,KAAK,EAAE,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC,MAAM,EAAE,OAAO,CAAC;IAChG;AACA;;;;;AAKG;IACH,YAAY,CAAC,MAA4B,EAAE,OAA8B,EAAA;QACvE,OAAO,IAAI,CAAC,OAAO,CAAC,kBAAkB,EAAE,QAAQ,EAAE,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC,MAAM,EAAE,OAAO,CAAC;IACnG;AACA;;;;;AAKG;IACH,WAAW,CAAC,MAA2B,EAAE,OAA8B,EAAA;QACrE,OAAO,IAAI,CAAC,OAAO,CAAC,0BAA0B,EAAE,QAAQ,EAAE,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC,MAAM,EAAE,OAAO,CAAC;IAC3G;AACA;;;;;AAKG;IACH,WAAW,CAAC,MAA2B,EAAE,OAA8B,EAAA;QACrE,OAAO,IAAI,CAAC,OAAO,CAAC,gCAAgC,EAAE,KAAK,EAAE,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC,MAAM,EAAE,OAAO,CAAC;IAC9G;AACA;;;;;AAKG;IACH,eAAe,CAAC,MAA+B,EAAE,OAA8B,EAAA;QAC7E,OAAO,IAAI,CAAC,OAAO,CAAC,gCAAgC,EAAE,MAAM,EAAE,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC,MAAM,EAAE,OAAO,CAAC;IAC/G;AACA;;;;;AAKG;IACH,YAAY,CAAC,MAA4B,EAAE,OAA8B,EAAA;QACvE,OAAO,IAAI,CAAC,OAAO,CAAC,gCAAgC,EAAE,QAAQ,EAAE,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC,MAAM,EAAE,OAAO,CAAC;IACjH;AACD;;;;"}
@@ -36,7 +36,7 @@ export type ErxGetMedicationHistoryResponse = {
36
36
  schedule: number | null;
37
37
  directions: string | null;
38
38
  substitutionsAllowed: boolean;
39
- writtenDate: string;
39
+ writtenDate: string | null;
40
40
  effectiveDate: string | null;
41
41
  lastFillDate: string | null;
42
42
  expirationDate: string | null;
@@ -0,0 +1,3 @@
1
+ export interface ErxGetPharmacyParams {
2
+ pharmacyId: string;
3
+ }
@@ -0,0 +1,16 @@
1
+ /**
2
+ * Success
3
+ */
4
+ export interface ErxGetPharmacyResponse {
5
+ id: number;
6
+ name: string;
7
+ address1: string;
8
+ address2: string | null;
9
+ city: string;
10
+ state: string;
11
+ zipCode: string;
12
+ phone: string;
13
+ fax: string | null;
14
+ specialties: string[];
15
+ ncpdpId: string;
16
+ }
@@ -6,12 +6,12 @@ export interface ErxSearchPharmaciesResponse {
6
6
  id: number;
7
7
  name: string;
8
8
  address1: string;
9
- address2?: string;
9
+ address2: string | null;
10
10
  city: string;
11
11
  state: string;
12
12
  zipCode: string;
13
13
  phone: string;
14
- fax?: string;
14
+ fax: string | null;
15
15
  specialties: string[];
16
16
  ncpdpId: string;
17
17
  }[];
@@ -12,4 +12,8 @@ export interface LabOrderSubmitParams {
12
12
  * A client-provided string used to identify all tests in an order. See [Submit Lab](https://docs.oystehr.com/oystehr/services/lab/submit-an-order/#client-provided-order-number/) for more details.
13
13
  */
14
14
  orderNumber?: string;
15
+ /**
16
+ * Flag to indicate which patient ID to transmit on the lab order. Defaults to false, instead using the Patient resource's UUID. If set to true but no friendly ID is found, throws a 400 error. See [Friendly Patient ID](https://docs.oystehr.com/oystehr/services/fhir/friendly-patient-id/) for more information on the friendly ID. See [Submit Lab](https://docs.oystehr.com/oystehr/services/lab/submit-an-order/#friendly-patient-id-in-lab-orders/) for more information on submitting using the friendly ID.
17
+ */
18
+ useFriendlyPatientId?: boolean;
15
19
  }
@@ -0,0 +1,6 @@
1
+ export interface RcmProcessEraParams {
2
+ /**
3
+ * EDI835 X12 string representing ERA
4
+ */
5
+ edi835: string;
6
+ }
@@ -0,0 +1,5 @@
1
+ import { Bundle } from 'fhir/r4b';
2
+ /**
3
+ * Bundle with FHIR transaction output with resources created after procesing ERA.
4
+ */
5
+ export type RcmProcessEraResponse = Bundle;
@@ -0,0 +1,9 @@
1
+ export interface TerminologySearchIcd10Params {
2
+ query: string;
3
+ searchType?: 'code' | 'description' | 'all';
4
+ limit?: number;
5
+ cursor?: string;
6
+ strictMatch?: boolean;
7
+ includeSynonyms?: boolean;
8
+ specialty?: 'urgent-care'[];
9
+ }
@@ -0,0 +1,27 @@
1
+ /**
2
+ * ICD-10-CM code search results
3
+ */
4
+ export interface TerminologySearchIcd10Response {
5
+ /**
6
+ * Array of ICD-10-CM codes matching the search.
7
+ */
8
+ codes: {
9
+ /**
10
+ * ICD-10-CM code.
11
+ */
12
+ code: string;
13
+ /**
14
+ * Human-readable description of the ICD-10-CM code.
15
+ */
16
+ display: string;
17
+ }[];
18
+ /**
19
+ * Pagination metadata.
20
+ */
21
+ metadata: {
22
+ /**
23
+ * Cursor for the next page of results. Null if no more results.
24
+ */
25
+ nextCursor: string | null;
26
+ };
27
+ }
@@ -0,0 +1,3 @@
1
+ export interface Z3EmptyBucketParams {
2
+ bucketName: string;
3
+ }
@@ -0,0 +1,9 @@
1
+ /**
2
+ * Z3 Bucket was emptied successfully.
3
+ */
4
+ export interface Z3EmptyBucketResponse {
5
+ /**
6
+ * The number of Z3 Objects deleted from the bucket.
7
+ */
8
+ deletedCount: number;
9
+ }
@@ -93,6 +93,19 @@ export interface BatchInputPostRequest<F extends FhirResource> extends BatchInpu
93
93
  method: 'POST';
94
94
  resource: F;
95
95
  fullUrl?: string;
96
+ /**
97
+ * Perform a FHIR conditional create for this entry using the bundle entry's `ifNoneExist`
98
+ * field. The value is a FHIR search query that identifies whether a matching resource already
99
+ * exists: if no resource matches, the resource is created; if exactly one matches, no resource
100
+ * is created and the existing one is returned; if more than one matches, the entry fails with a
101
+ * 412 Precondition Failed error.
102
+ *
103
+ * Accepts either a raw search query string (e.g. `'identifier=http://acme.org|1234'`) or an
104
+ * array of SearchParam objects (e.g. `[{ name: 'identifier', value: 'http://acme.org|1234' }]`).
105
+ *
106
+ * @see https://www.hl7.org/fhir/http.html#cond-update
107
+ */
108
+ ifNoneExist?: string | SearchParam[];
96
109
  }
97
110
  /**
98
111
  * A batch POST to a `_search` endpoint (e.g. `Patient/_search`). Search parameters
@@ -121,6 +121,8 @@ export * from './Z3ListBucketsResponse';
121
121
  export * from './Z3CreateBucketParams';
122
122
  export * from './Z3CreateBucketResponse';
123
123
  export * from './Z3DeleteBucketParams';
124
+ export * from './Z3EmptyBucketParams';
125
+ export * from './Z3EmptyBucketResponse';
124
126
  export * from './Z3ListObjectsParams';
125
127
  export * from './Z3ListObjectsResponse';
126
128
  export * from './Z3GetPresignedUrlParams';
@@ -163,6 +165,8 @@ export * from './ErxCancelPrescriptionParams';
163
165
  export * from './ErxSyncPatientParams';
164
166
  export * from './ErxSearchPharmaciesParams';
165
167
  export * from './ErxSearchPharmaciesResponse';
168
+ export * from './ErxGetPharmacyParams';
169
+ export * from './ErxGetPharmacyResponse';
166
170
  export * from './ErxConnectPractitionerParams';
167
171
  export * from './ErxConnectPractitionerResponse';
168
172
  export * from './ErxCheckPractitionerEnrollmentParams';
@@ -173,6 +177,8 @@ export * from './TerminologySearchCptParams';
173
177
  export * from './TerminologySearchCptResponse';
174
178
  export * from './TerminologySearchHcpcsParams';
175
179
  export * from './TerminologySearchHcpcsResponse';
180
+ export * from './TerminologySearchIcd10Params';
181
+ export * from './TerminologySearchIcd10Response';
176
182
  export * from './ZambdaSchedule';
177
183
  export * from './ZambdaFunction';
178
184
  export * from './ZambdaExecuteResult';
@@ -208,3 +214,5 @@ export * from './RcmListPayersParams';
208
214
  export * from './RcmListPayersResponse';
209
215
  export * from './RcmGetPayerParams';
210
216
  export * from './RcmGetPayerResponse';
217
+ export * from './RcmProcessEraParams';
218
+ export * from './RcmProcessEraResponse';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@oystehr/sdk",
3
- "version": "4.3.10",
3
+ "version": "4.3.12",
4
4
  "description": "Oystehr SDK",
5
5
  "scripts": {
6
6
  "lint": "eslint .",
@@ -59,6 +59,11 @@ export interface OystehrClientRequest {
59
59
 
60
60
  interface InternalClientRequest extends OystehrClientRequest {
61
61
  ifMatch?: string;
62
+ /**
63
+ * Internal-only: the value of the 'If-None-Exist' header, used for FHIR
64
+ * conditional creates. A FHIR search query string (e.g. "identifier=sys|123").
65
+ */
66
+ ifNoneExist?: string;
62
67
  /**
63
68
  * Internal-only: returns raw response metadata ({ status, headers, body }) instead of throwing on non-2xx statuses.
64
69
  */
@@ -299,11 +304,16 @@ function isInternalClientRequest(request: Record<string, any>): request is Inter
299
304
  ('contentType' in request && request.contentType?.split('/').length === 2) ||
300
305
  'requestId' in request ||
301
306
  ('ifMatch' in request && request.ifMatch.startsWith('W/"')) ||
307
+ 'ifNoneExist' in request ||
302
308
  'mode' in request ||
303
309
  'rawResponse' in request
304
310
  );
305
311
  }
306
312
 
313
+ function isResourcePayload(params: Record<string, unknown>): boolean {
314
+ return typeof params.resourceType === 'string' && params.resourceType.length > 0;
315
+ }
316
+
307
317
  function getPreferHeaderFromMode(mode: FhirResponseMode | undefined): string | undefined {
308
318
  if (mode === 'async-bundle' || mode === 'async-bulk') {
309
319
  return 'respond-async';
@@ -422,6 +432,7 @@ function fetcher(
422
432
  preferHeader ? { Prefer: preferHeader } : {},
423
433
  accessToken ? { Authorization: `Bearer ${accessToken}` } : {},
424
434
  requestCtx?.ifMatch ? { 'If-Match': requestCtx.ifMatch } : {},
435
+ requestCtx?.ifNoneExist ? { 'If-None-Exist': requestCtx.ifNoneExist } : {},
425
436
  { 'x-oystehr-request-id': requestCtx?.requestId }
426
437
  );
427
438
  const retryConfig: ConstructedRetryConfig = {
@@ -628,13 +639,16 @@ export function extractParamsAndRequest(
628
639
  params?: Record<string, unknown> | [any] | InternalClientRequest,
629
640
  request?: InternalClientRequest
630
641
  ): [Record<string, unknown>, InternalClientRequest | undefined] {
631
- const providedParams: Record<string, unknown> | [any] =
632
- !!params && !request && !Array.isArray(params) && isInternalClientRequest(params)
633
- ? {}
634
- : (params as Record<string, unknown>) ?? {};
635
- const requestCtx =
636
- !!params && !request && !Array.isArray(params) && isInternalClientRequest(params)
637
- ? (params as InternalClientRequest)
638
- : request;
642
+ const shouldUseFirstArgAsRequest =
643
+ !!params &&
644
+ !request &&
645
+ !Array.isArray(params) &&
646
+ isInternalClientRequest(params) &&
647
+ !isResourcePayload(params as Record<string, unknown>);
648
+
649
+ const providedParams: Record<string, unknown> | [any] = shouldUseFirstArgAsRequest
650
+ ? {}
651
+ : (params as Record<string, unknown>) ?? {};
652
+ const requestCtx = shouldUseFirstArgAsRequest ? (params as InternalClientRequest) : request;
639
653
  return [providedParams, requestCtx];
640
654
  }
@@ -19,6 +19,8 @@ import {
19
19
  ErxGetMedicationHistoryResponse,
20
20
  ErxGetMedicationParams,
21
21
  ErxGetMedicationResponse,
22
+ ErxGetPharmacyParams,
23
+ ErxGetPharmacyResponse,
22
24
  ErxSearchAllergensParams,
23
25
  ErxSearchAllergensResponse,
24
26
  ErxSearchMedicationsParams,
@@ -206,6 +208,14 @@ export class Erx extends SDKResource {
206
208
  ): Promise<ErxSearchPharmaciesResponse> {
207
209
  return this.request('/pharmacy', 'get', this.#baseUrlThunk.bind(this))(params, request);
208
210
  }
211
+ /**
212
+ * Get a pharmacy by its eRx pharmacy ID.
213
+ * Action: `eRx:GetPharmacy`
214
+ * Access Policy Resource: `eRx:Pharmacy`
215
+ */
216
+ getPharmacy(params: ErxGetPharmacyParams, request?: OystehrClientRequest): Promise<ErxGetPharmacyResponse> {
217
+ return this.request('/pharmacy/{pharmacyId}', 'get', this.#baseUrlThunk.bind(this))(params, request);
218
+ }
209
219
  /**
210
220
  * Create an SSO link for a practitioner. This link can be used to log in to the eRx service as the specified practitioner.
211
221
  * Action: `eRx:Connect`