@squonk/account-server-client 4.4.0-4-4.2195235454 → 4.4.0-4-4.2197467763
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.
- package/dist/api/actions/actions.cjs +29 -18
- package/dist/api/actions/actions.cjs.map +1 -1
- package/dist/api/actions/actions.d.cts +12 -7
- package/dist/api/actions/actions.d.cts.map +1 -1
- package/dist/api/actions/actions.d.ts +12 -7
- package/dist/api/actions/actions.d.ts.map +1 -1
- package/dist/api/actions/actions.fetch.cjs +98 -0
- package/dist/api/actions/actions.fetch.cjs.map +1 -0
- package/dist/api/actions/actions.fetch.d.cts +77 -0
- package/dist/api/actions/actions.fetch.d.cts.map +1 -0
- package/dist/api/actions/actions.fetch.d.ts +77 -0
- package/dist/api/actions/actions.fetch.d.ts.map +1 -0
- package/dist/api/actions/actions.fetch.js +90 -0
- package/dist/api/actions/actions.fetch.js.map +1 -0
- package/dist/api/actions/actions.js +26 -16
- package/dist/api/actions/actions.js.map +1 -1
- package/dist/api/api-schemas/actionDetail.d.cts +17 -0
- package/dist/api/api-schemas/actionDetail.d.cts.map +1 -0
- package/dist/api/api-schemas/actionDetail.d.ts +17 -0
- package/dist/api/api-schemas/actionDetail.d.ts.map +1 -0
- package/dist/api/api-schemas/actionGetResponse.d.cts +15 -0
- package/dist/api/api-schemas/actionGetResponse.d.cts.map +1 -0
- package/dist/api/api-schemas/actionGetResponse.d.ts +15 -0
- package/dist/api/api-schemas/actionGetResponse.d.ts.map +1 -0
- package/dist/api/api-schemas/asError.d.cts +18 -0
- package/dist/api/api-schemas/asError.d.cts.map +1 -0
- package/dist/api/api-schemas/asError.d.ts +18 -0
- package/dist/api/api-schemas/asError.d.ts.map +1 -0
- package/dist/api/api-schemas/assetDetail.d.cts +22 -0
- package/dist/api/api-schemas/assetDetail.d.cts.map +1 -0
- package/dist/api/api-schemas/assetDetail.d.ts +22 -0
- package/dist/api/api-schemas/assetDetail.d.ts.map +1 -0
- package/dist/api/api-schemas/assetDetailScope.cjs +13 -0
- package/dist/api/api-schemas/assetDetailScope.cjs.map +1 -0
- package/dist/api/api-schemas/assetDetailScope.d.cts +22 -0
- package/dist/api/api-schemas/assetDetailScope.d.cts.map +1 -0
- package/dist/api/api-schemas/assetDetailScope.d.ts +22 -0
- package/dist/api/api-schemas/assetDetailScope.d.ts.map +1 -0
- package/dist/api/api-schemas/assetDetailScope.js +12 -0
- package/dist/api/api-schemas/assetDetailScope.js.map +1 -0
- package/dist/api/api-schemas/assetGetByIdResponse.d.cts +8 -0
- package/dist/api/api-schemas/assetGetByIdResponse.d.cts.map +1 -0
- package/dist/api/api-schemas/assetGetByIdResponse.d.ts +8 -0
- package/dist/api/api-schemas/assetGetByIdResponse.d.ts.map +1 -0
- package/dist/api/api-schemas/assetGetResponse.d.cts +15 -0
- package/dist/api/api-schemas/assetGetResponse.d.cts.map +1 -0
- package/dist/api/api-schemas/assetGetResponse.d.ts +15 -0
- package/dist/api/api-schemas/assetGetResponse.d.ts.map +1 -0
- package/dist/api/api-schemas/assetPatchBodyBody.d.cts +22 -0
- package/dist/api/api-schemas/assetPatchBodyBody.d.cts.map +1 -0
- package/dist/api/api-schemas/assetPatchBodyBody.d.ts +22 -0
- package/dist/api/api-schemas/assetPatchBodyBody.d.ts.map +1 -0
- package/dist/api/api-schemas/assetPostBodyBody.d.cts +27 -0
- package/dist/api/api-schemas/assetPostBodyBody.d.cts.map +1 -0
- package/dist/api/api-schemas/assetPostBodyBody.d.ts +27 -0
- package/dist/api/api-schemas/assetPostBodyBody.d.ts.map +1 -0
- package/dist/api/api-schemas/assetPostBodyBodyScope.cjs +13 -0
- package/dist/api/api-schemas/assetPostBodyBodyScope.cjs.map +1 -0
- package/dist/api/api-schemas/assetPostBodyBodyScope.d.cts +25 -0
- package/dist/api/api-schemas/assetPostBodyBodyScope.d.cts.map +1 -0
- package/dist/api/api-schemas/assetPostBodyBodyScope.d.ts +25 -0
- package/dist/api/api-schemas/assetPostBodyBodyScope.d.ts.map +1 -0
- package/dist/api/api-schemas/assetPostBodyBodyScope.js +12 -0
- package/dist/api/api-schemas/assetPostBodyBodyScope.js.map +1 -0
- package/dist/api/api-schemas/assetPostResponse.d.cts +19 -0
- package/dist/api/api-schemas/assetPostResponse.d.cts.map +1 -0
- package/dist/api/api-schemas/assetPostResponse.d.ts +19 -0
- package/dist/api/api-schemas/assetPostResponse.d.ts.map +1 -0
- package/dist/api/api-schemas/attachAssetParams.d.cts +14 -0
- package/dist/api/api-schemas/attachAssetParams.d.cts.map +1 -0
- package/dist/api/api-schemas/attachAssetParams.d.ts +14 -0
- package/dist/api/api-schemas/attachAssetParams.d.ts.map +1 -0
- package/dist/api/api-schemas/chargeAdditionalData.d.cts +17 -0
- package/dist/api/api-schemas/chargeAdditionalData.d.cts.map +1 -0
- package/dist/api/api-schemas/chargeAdditionalData.d.ts +17 -0
- package/dist/api/api-schemas/chargeAdditionalData.d.ts.map +1 -0
- package/dist/api/api-schemas/chargeSummary.d.cts +13 -0
- package/dist/api/api-schemas/chargeSummary.d.cts.map +1 -0
- package/dist/api/api-schemas/chargeSummary.d.ts +13 -0
- package/dist/api/api-schemas/chargeSummary.d.ts.map +1 -0
- package/dist/api/api-schemas/chargeSummaryType.cjs +10 -0
- package/dist/api/api-schemas/chargeSummaryType.cjs.map +1 -0
- package/dist/api/api-schemas/chargeSummaryType.d.cts +22 -0
- package/dist/api/api-schemas/chargeSummaryType.d.cts.map +1 -0
- package/dist/api/api-schemas/chargeSummaryType.d.ts +22 -0
- package/dist/api/api-schemas/chargeSummaryType.d.ts.map +1 -0
- package/dist/api/api-schemas/chargeSummaryType.js +9 -0
- package/dist/api/api-schemas/chargeSummaryType.js.map +1 -0
- package/dist/api/api-schemas/chargesGetResponse.d.cts +14 -0
- package/dist/api/api-schemas/chargesGetResponse.d.cts.map +1 -0
- package/dist/api/api-schemas/chargesGetResponse.d.ts +14 -0
- package/dist/api/api-schemas/chargesGetResponse.d.ts.map +1 -0
- package/dist/api/api-schemas/detachAssetParams.d.cts +14 -0
- package/dist/api/api-schemas/detachAssetParams.d.cts.map +1 -0
- package/dist/api/api-schemas/detachAssetParams.d.ts +14 -0
- package/dist/api/api-schemas/detachAssetParams.d.ts.map +1 -0
- package/dist/api/api-schemas/eventStreamGetPostResponse.d.cts +24 -0
- package/dist/api/api-schemas/eventStreamGetPostResponse.d.cts.map +1 -0
- package/dist/api/api-schemas/eventStreamGetPostResponse.d.ts +24 -0
- package/dist/api/api-schemas/eventStreamGetPostResponse.d.ts.map +1 -0
- package/dist/api/api-schemas/eventStreamPostBodyBody.d.cts +10 -0
- package/dist/api/api-schemas/eventStreamPostBodyBody.d.cts.map +1 -0
- package/dist/api/api-schemas/eventStreamPostBodyBody.d.ts +10 -0
- package/dist/api/api-schemas/eventStreamPostBodyBody.d.ts.map +1 -0
- package/dist/api/api-schemas/eventStreamPostBodyBodyFormat.cjs +10 -0
- package/dist/api/api-schemas/eventStreamPostBodyBodyFormat.cjs.map +1 -0
- package/dist/api/api-schemas/eventStreamPostBodyBodyFormat.d.cts +19 -0
- package/dist/api/api-schemas/eventStreamPostBodyBodyFormat.d.cts.map +1 -0
- package/dist/api/api-schemas/eventStreamPostBodyBodyFormat.d.ts +19 -0
- package/dist/api/api-schemas/eventStreamPostBodyBodyFormat.d.ts.map +1 -0
- package/dist/api/api-schemas/eventStreamPostBodyBodyFormat.js +9 -0
- package/dist/api/api-schemas/eventStreamPostBodyBodyFormat.js.map +1 -0
- package/dist/api/api-schemas/eventStreamVersionGetResponse.d.cts +15 -0
- package/dist/api/api-schemas/eventStreamVersionGetResponse.d.cts.map +1 -0
- package/dist/api/api-schemas/eventStreamVersionGetResponse.d.ts +15 -0
- package/dist/api/api-schemas/eventStreamVersionGetResponse.d.ts.map +1 -0
- package/dist/api/api-schemas/eventStreamVersionGetResponseProtocol.cjs +11 -0
- package/dist/api/api-schemas/eventStreamVersionGetResponseProtocol.cjs.map +1 -0
- package/dist/api/api-schemas/eventStreamVersionGetResponseProtocol.d.cts +23 -0
- package/dist/api/api-schemas/eventStreamVersionGetResponseProtocol.d.cts.map +1 -0
- package/dist/api/api-schemas/eventStreamVersionGetResponseProtocol.d.ts +23 -0
- package/dist/api/api-schemas/eventStreamVersionGetResponseProtocol.d.ts.map +1 -0
- package/dist/api/api-schemas/eventStreamVersionGetResponseProtocol.js +10 -0
- package/dist/api/api-schemas/eventStreamVersionGetResponseProtocol.js.map +1 -0
- package/dist/api/api-schemas/getActionsParams.d.cts +47 -0
- package/dist/api/api-schemas/getActionsParams.d.cts.map +1 -0
- package/dist/api/api-schemas/getActionsParams.d.ts +47 -0
- package/dist/api/api-schemas/getActionsParams.d.ts.map +1 -0
- package/dist/api/api-schemas/getAssetParams.d.cts +34 -0
- package/dist/api/api-schemas/getAssetParams.d.cts.map +1 -0
- package/dist/api/api-schemas/getAssetParams.d.ts +34 -0
- package/dist/api/api-schemas/getAssetParams.d.ts.map +1 -0
- package/dist/api/api-schemas/getChargesParams.d.cts +25 -0
- package/dist/api/api-schemas/getChargesParams.d.cts.map +1 -0
- package/dist/api/api-schemas/getChargesParams.d.ts +25 -0
- package/dist/api/api-schemas/getChargesParams.d.ts.map +1 -0
- package/dist/api/api-schemas/getOrganisationChargesParams.d.cts +25 -0
- package/dist/api/api-schemas/getOrganisationChargesParams.d.cts.map +1 -0
- package/dist/api/api-schemas/getOrganisationChargesParams.d.ts +25 -0
- package/dist/api/api-schemas/getOrganisationChargesParams.d.ts.map +1 -0
- package/dist/api/api-schemas/getOrganisationsParams.d.cts +13 -0
- package/dist/api/api-schemas/getOrganisationsParams.d.cts.map +1 -0
- package/dist/api/api-schemas/getOrganisationsParams.d.ts +13 -0
- package/dist/api/api-schemas/getOrganisationsParams.d.ts.map +1 -0
- package/dist/api/api-schemas/getProductChargesParams.d.cts +25 -0
- package/dist/api/api-schemas/getProductChargesParams.d.cts.map +1 -0
- package/dist/api/api-schemas/getProductChargesParams.d.ts +25 -0
- package/dist/api/api-schemas/getProductChargesParams.d.ts.map +1 -0
- package/dist/api/api-schemas/getUnitChargesParams.d.cts +25 -0
- package/dist/api/api-schemas/getUnitChargesParams.d.cts.map +1 -0
- package/dist/api/api-schemas/getUnitChargesParams.d.ts +25 -0
- package/dist/api/api-schemas/getUnitChargesParams.d.ts.map +1 -0
- package/dist/api/api-schemas/getUnitsParams.d.cts +13 -0
- package/dist/api/api-schemas/getUnitsParams.d.cts.map +1 -0
- package/dist/api/api-schemas/getUnitsParams.d.ts +13 -0
- package/dist/api/api-schemas/getUnitsParams.d.ts.map +1 -0
- package/dist/api/api-schemas/merchantDetail.d.cts +18 -0
- package/dist/api/api-schemas/merchantDetail.d.cts.map +1 -0
- package/dist/api/api-schemas/merchantDetail.d.ts +18 -0
- package/dist/api/api-schemas/merchantDetail.d.ts.map +1 -0
- package/dist/api/api-schemas/merchantDetailKind.cjs +7 -0
- package/dist/api/api-schemas/merchantDetailKind.cjs.map +1 -0
- package/dist/api/api-schemas/merchantDetailKind.d.cts +21 -0
- package/dist/api/api-schemas/merchantDetailKind.d.cts.map +1 -0
- package/dist/api/api-schemas/merchantDetailKind.d.ts +21 -0
- package/dist/api/api-schemas/merchantDetailKind.d.ts.map +1 -0
- package/dist/api/api-schemas/merchantDetailKind.js +6 -0
- package/dist/api/api-schemas/merchantDetailKind.js.map +1 -0
- package/dist/api/api-schemas/merchantGetResponse.d.cts +8 -0
- package/dist/api/api-schemas/merchantGetResponse.d.cts.map +1 -0
- package/dist/api/api-schemas/merchantGetResponse.d.ts +8 -0
- package/dist/api/api-schemas/merchantGetResponse.d.ts.map +1 -0
- package/dist/api/api-schemas/merchantSummary.d.cts +15 -0
- package/dist/api/api-schemas/merchantSummary.d.cts.map +1 -0
- package/dist/api/api-schemas/merchantSummary.d.ts +15 -0
- package/dist/api/api-schemas/merchantSummary.d.ts.map +1 -0
- package/dist/api/api-schemas/merchantSummaryKind.cjs +7 -0
- package/dist/api/api-schemas/merchantSummaryKind.cjs.map +1 -0
- package/dist/api/api-schemas/merchantSummaryKind.d.cts +21 -0
- package/dist/api/api-schemas/merchantSummaryKind.d.cts.map +1 -0
- package/dist/api/api-schemas/merchantSummaryKind.d.ts +21 -0
- package/dist/api/api-schemas/merchantSummaryKind.d.ts.map +1 -0
- package/dist/api/api-schemas/merchantSummaryKind.js +6 -0
- package/dist/api/api-schemas/merchantSummaryKind.js.map +1 -0
- package/dist/api/api-schemas/merchantsGetResponse.d.cts +13 -0
- package/dist/api/api-schemas/merchantsGetResponse.d.cts.map +1 -0
- package/dist/api/api-schemas/merchantsGetResponse.d.ts +13 -0
- package/dist/api/api-schemas/merchantsGetResponse.d.ts.map +1 -0
- package/dist/api/api-schemas/organisationAllDetail.d.cts +25 -0
- package/dist/api/api-schemas/organisationAllDetail.d.cts.map +1 -0
- package/dist/api/api-schemas/organisationAllDetail.d.ts +25 -0
- package/dist/api/api-schemas/organisationAllDetail.d.ts.map +1 -0
- package/dist/api/api-schemas/organisationAllDetailDefaultProductPrivacy.cjs +12 -0
- package/dist/api/api-schemas/organisationAllDetailDefaultProductPrivacy.cjs.map +1 -0
- package/dist/api/api-schemas/organisationAllDetailDefaultProductPrivacy.d.cts +24 -0
- package/dist/api/api-schemas/organisationAllDetailDefaultProductPrivacy.d.cts.map +1 -0
- package/dist/api/api-schemas/organisationAllDetailDefaultProductPrivacy.d.ts +24 -0
- package/dist/api/api-schemas/organisationAllDetailDefaultProductPrivacy.d.ts.map +1 -0
- package/dist/api/api-schemas/organisationAllDetailDefaultProductPrivacy.js +11 -0
- package/dist/api/api-schemas/organisationAllDetailDefaultProductPrivacy.js.map +1 -0
- package/dist/api/api-schemas/organisationChargeSummary.d.cts +12 -0
- package/dist/api/api-schemas/organisationChargeSummary.d.cts.map +1 -0
- package/dist/api/api-schemas/organisationChargeSummary.d.ts +12 -0
- package/dist/api/api-schemas/organisationChargeSummary.d.ts.map +1 -0
- package/dist/api/api-schemas/organisationChargesGetResponse.d.cts +15 -0
- package/dist/api/api-schemas/organisationChargesGetResponse.d.cts.map +1 -0
- package/dist/api/api-schemas/organisationChargesGetResponse.d.ts +15 -0
- package/dist/api/api-schemas/organisationChargesGetResponse.d.ts.map +1 -0
- package/dist/api/api-schemas/organisationDetail.d.cts +22 -0
- package/dist/api/api-schemas/organisationDetail.d.cts.map +1 -0
- package/dist/api/api-schemas/organisationDetail.d.ts +22 -0
- package/dist/api/api-schemas/organisationDetail.d.ts.map +1 -0
- package/dist/api/api-schemas/organisationDetailDefaultProductPrivacy.cjs +12 -0
- package/dist/api/api-schemas/organisationDetailDefaultProductPrivacy.cjs.map +1 -0
- package/dist/api/api-schemas/organisationDetailDefaultProductPrivacy.d.cts +24 -0
- package/dist/api/api-schemas/organisationDetailDefaultProductPrivacy.d.cts.map +1 -0
- package/dist/api/api-schemas/organisationDetailDefaultProductPrivacy.d.ts +24 -0
- package/dist/api/api-schemas/organisationDetailDefaultProductPrivacy.d.ts.map +1 -0
- package/dist/api/api-schemas/organisationDetailDefaultProductPrivacy.js +11 -0
- package/dist/api/api-schemas/organisationDetailDefaultProductPrivacy.js.map +1 -0
- package/dist/api/api-schemas/organisationGetDefaultResponse.d.cts +23 -0
- package/dist/api/api-schemas/organisationGetDefaultResponse.d.cts.map +1 -0
- package/dist/api/api-schemas/organisationGetDefaultResponse.d.ts +23 -0
- package/dist/api/api-schemas/organisationGetDefaultResponse.d.ts.map +1 -0
- package/dist/api/api-schemas/organisationGetDefaultResponseDefaultProductPrivacy.cjs +12 -0
- package/dist/api/api-schemas/organisationGetDefaultResponseDefaultProductPrivacy.cjs.map +1 -0
- package/dist/api/api-schemas/organisationGetDefaultResponseDefaultProductPrivacy.d.cts +24 -0
- package/dist/api/api-schemas/organisationGetDefaultResponseDefaultProductPrivacy.d.cts.map +1 -0
- package/dist/api/api-schemas/organisationGetDefaultResponseDefaultProductPrivacy.d.ts +24 -0
- package/dist/api/api-schemas/organisationGetDefaultResponseDefaultProductPrivacy.d.ts.map +1 -0
- package/dist/api/api-schemas/organisationGetDefaultResponseDefaultProductPrivacy.js +11 -0
- package/dist/api/api-schemas/organisationGetDefaultResponseDefaultProductPrivacy.js.map +1 -0
- package/dist/api/api-schemas/organisationGetResponse.d.cts +8 -0
- package/dist/api/api-schemas/organisationGetResponse.d.cts.map +1 -0
- package/dist/api/api-schemas/organisationGetResponse.d.ts +8 -0
- package/dist/api/api-schemas/organisationGetResponse.d.ts.map +1 -0
- package/dist/api/api-schemas/organisationPatchBodyBody.d.cts +14 -0
- package/dist/api/api-schemas/organisationPatchBodyBody.d.cts.map +1 -0
- package/dist/api/api-schemas/organisationPatchBodyBody.d.ts +14 -0
- package/dist/api/api-schemas/organisationPatchBodyBody.d.ts.map +1 -0
- package/dist/api/api-schemas/organisationPatchBodyBodyDefaultProductPrivacy.cjs +12 -0
- package/dist/api/api-schemas/organisationPatchBodyBodyDefaultProductPrivacy.cjs.map +1 -0
- package/dist/api/api-schemas/organisationPatchBodyBodyDefaultProductPrivacy.d.cts +26 -0
- package/dist/api/api-schemas/organisationPatchBodyBodyDefaultProductPrivacy.d.cts.map +1 -0
- package/dist/api/api-schemas/organisationPatchBodyBodyDefaultProductPrivacy.d.ts +26 -0
- package/dist/api/api-schemas/organisationPatchBodyBodyDefaultProductPrivacy.d.ts.map +1 -0
- package/dist/api/api-schemas/organisationPatchBodyBodyDefaultProductPrivacy.js +11 -0
- package/dist/api/api-schemas/organisationPatchBodyBodyDefaultProductPrivacy.js.map +1 -0
- package/dist/api/api-schemas/organisationPostBodyBody.d.cts +18 -0
- package/dist/api/api-schemas/organisationPostBodyBody.d.cts.map +1 -0
- package/dist/api/api-schemas/organisationPostBodyBody.d.ts +18 -0
- package/dist/api/api-schemas/organisationPostBodyBody.d.ts.map +1 -0
- package/dist/api/api-schemas/organisationPostBodyBodyDefaultProductPrivacy.cjs +12 -0
- package/dist/api/api-schemas/organisationPostBodyBodyDefaultProductPrivacy.cjs.map +1 -0
- package/dist/api/api-schemas/organisationPostBodyBodyDefaultProductPrivacy.d.cts +24 -0
- package/dist/api/api-schemas/organisationPostBodyBodyDefaultProductPrivacy.d.cts.map +1 -0
- package/dist/api/api-schemas/organisationPostBodyBodyDefaultProductPrivacy.d.ts +24 -0
- package/dist/api/api-schemas/organisationPostBodyBodyDefaultProductPrivacy.d.ts.map +1 -0
- package/dist/api/api-schemas/organisationPostBodyBodyDefaultProductPrivacy.js +11 -0
- package/dist/api/api-schemas/organisationPostBodyBodyDefaultProductPrivacy.js.map +1 -0
- package/dist/api/api-schemas/organisationPostResponse.d.cts +18 -0
- package/dist/api/api-schemas/organisationPostResponse.d.cts.map +1 -0
- package/dist/api/api-schemas/organisationPostResponse.d.ts +18 -0
- package/dist/api/api-schemas/organisationPostResponse.d.ts.map +1 -0
- package/dist/api/api-schemas/organisationUnitChargeSummary.d.cts +21 -0
- package/dist/api/api-schemas/organisationUnitChargeSummary.d.cts.map +1 -0
- package/dist/api/api-schemas/organisationUnitChargeSummary.d.ts +21 -0
- package/dist/api/api-schemas/organisationUnitChargeSummary.d.ts.map +1 -0
- package/dist/api/api-schemas/organisationUnitPostBodyBody.d.cts +22 -0
- package/dist/api/api-schemas/organisationUnitPostBodyBody.d.cts.map +1 -0
- package/dist/api/api-schemas/organisationUnitPostBodyBody.d.ts +22 -0
- package/dist/api/api-schemas/organisationUnitPostBodyBody.d.ts.map +1 -0
- package/dist/api/api-schemas/organisationUnitPostBodyBodyDefaultProductPrivacy.cjs +12 -0
- package/dist/api/api-schemas/organisationUnitPostBodyBodyDefaultProductPrivacy.cjs.map +1 -0
- package/dist/api/api-schemas/organisationUnitPostBodyBodyDefaultProductPrivacy.d.cts +24 -0
- package/dist/api/api-schemas/organisationUnitPostBodyBodyDefaultProductPrivacy.d.cts.map +1 -0
- package/dist/api/api-schemas/organisationUnitPostBodyBodyDefaultProductPrivacy.d.ts +24 -0
- package/dist/api/api-schemas/organisationUnitPostBodyBodyDefaultProductPrivacy.d.ts.map +1 -0
- package/dist/api/api-schemas/organisationUnitPostBodyBodyDefaultProductPrivacy.js +11 -0
- package/dist/api/api-schemas/organisationUnitPostBodyBodyDefaultProductPrivacy.js.map +1 -0
- package/dist/api/api-schemas/organisationUnitPostResponse.d.cts +18 -0
- package/dist/api/api-schemas/organisationUnitPostResponse.d.cts.map +1 -0
- package/dist/api/api-schemas/organisationUnitPostResponse.d.ts +18 -0
- package/dist/api/api-schemas/organisationUnitPostResponse.d.ts.map +1 -0
- package/dist/api/api-schemas/organisationUnitsGetResponse.d.cts +15 -0
- package/dist/api/api-schemas/organisationUnitsGetResponse.d.cts.map +1 -0
- package/dist/api/api-schemas/organisationUnitsGetResponse.d.ts +15 -0
- package/dist/api/api-schemas/organisationUnitsGetResponse.d.ts.map +1 -0
- package/dist/api/api-schemas/organisationsGetResponse.d.cts +12 -0
- package/dist/api/api-schemas/organisationsGetResponse.d.cts.map +1 -0
- package/dist/api/api-schemas/organisationsGetResponse.d.ts +12 -0
- package/dist/api/api-schemas/organisationsGetResponse.d.ts.map +1 -0
- package/dist/api/api-schemas/personalUnitPutBodyBody.d.cts +22 -0
- package/dist/api/api-schemas/personalUnitPutBodyBody.d.cts.map +1 -0
- package/dist/api/api-schemas/personalUnitPutBodyBody.d.ts +22 -0
- package/dist/api/api-schemas/personalUnitPutBodyBody.d.ts.map +1 -0
- package/dist/api/api-schemas/personalUnitPutResponse.d.cts +20 -0
- package/dist/api/api-schemas/personalUnitPutResponse.d.cts.map +1 -0
- package/dist/api/api-schemas/personalUnitPutResponse.d.ts +20 -0
- package/dist/api/api-schemas/personalUnitPutResponse.d.ts.map +1 -0
- package/dist/api/api-schemas/processingChargeItem.d.cts +20 -0
- package/dist/api/api-schemas/processingChargeItem.d.cts.map +1 -0
- package/dist/api/api-schemas/processingChargeItem.d.ts +20 -0
- package/dist/api/api-schemas/processingChargeItem.d.ts.map +1 -0
- package/dist/api/api-schemas/processingCharges.d.cts +20 -0
- package/dist/api/api-schemas/processingCharges.d.cts.map +1 -0
- package/dist/api/api-schemas/processingCharges.d.ts +20 -0
- package/dist/api/api-schemas/processingCharges.d.ts.map +1 -0
- package/dist/api/api-schemas/processingChargesMerchantKind.cjs +7 -0
- package/dist/api/api-schemas/processingChargesMerchantKind.cjs.map +1 -0
- package/dist/api/api-schemas/processingChargesMerchantKind.d.cts +18 -0
- package/dist/api/api-schemas/processingChargesMerchantKind.d.cts.map +1 -0
- package/dist/api/api-schemas/processingChargesMerchantKind.d.ts +18 -0
- package/dist/api/api-schemas/processingChargesMerchantKind.d.ts.map +1 -0
- package/dist/api/api-schemas/processingChargesMerchantKind.js +6 -0
- package/dist/api/api-schemas/processingChargesMerchantKind.js.map +1 -0
- package/dist/api/api-schemas/productChargesGetResponse.d.cts +31 -0
- package/dist/api/api-schemas/productChargesGetResponse.d.cts.map +1 -0
- package/dist/api/api-schemas/productChargesGetResponse.d.ts +31 -0
- package/dist/api/api-schemas/productChargesGetResponse.d.ts.map +1 -0
- package/dist/api/api-schemas/productChargesGetResponseProductType.cjs +10 -0
- package/dist/api/api-schemas/productChargesGetResponseProductType.cjs.map +1 -0
- package/dist/api/api-schemas/productChargesGetResponseProductType.d.cts +19 -0
- package/dist/api/api-schemas/productChargesGetResponseProductType.d.cts.map +1 -0
- package/dist/api/api-schemas/productChargesGetResponseProductType.d.ts +19 -0
- package/dist/api/api-schemas/productChargesGetResponseProductType.d.ts.map +1 -0
- package/dist/api/api-schemas/productChargesGetResponseProductType.js +9 -0
- package/dist/api/api-schemas/productChargesGetResponseProductType.js.map +1 -0
- package/dist/api/api-schemas/productClaimDetail.d.cts +22 -0
- package/dist/api/api-schemas/productClaimDetail.d.cts.map +1 -0
- package/dist/api/api-schemas/productClaimDetail.d.ts +22 -0
- package/dist/api/api-schemas/productClaimDetail.d.ts.map +1 -0
- package/dist/api/api-schemas/productCoinsDetail.d.cts +38 -0
- package/dist/api/api-schemas/productCoinsDetail.d.cts.map +1 -0
- package/dist/api/api-schemas/productCoinsDetail.d.ts +38 -0
- package/dist/api/api-schemas/productCoinsDetail.d.ts.map +1 -0
- package/dist/api/api-schemas/productDetail.d.cts +23 -0
- package/dist/api/api-schemas/productDetail.d.cts.map +1 -0
- package/dist/api/api-schemas/productDetail.d.ts +23 -0
- package/dist/api/api-schemas/productDetail.d.ts.map +1 -0
- package/dist/api/api-schemas/productDetailFlavour.cjs +12 -0
- package/dist/api/api-schemas/productDetailFlavour.cjs.map +1 -0
- package/dist/api/api-schemas/productDetailFlavour.d.cts +25 -0
- package/dist/api/api-schemas/productDetailFlavour.d.cts.map +1 -0
- package/dist/api/api-schemas/productDetailFlavour.d.ts +25 -0
- package/dist/api/api-schemas/productDetailFlavour.d.ts.map +1 -0
- package/dist/api/api-schemas/productDetailFlavour.js +11 -0
- package/dist/api/api-schemas/productDetailFlavour.js.map +1 -0
- package/dist/api/api-schemas/productDetailType.cjs +10 -0
- package/dist/api/api-schemas/productDetailType.cjs.map +1 -0
- package/dist/api/api-schemas/productDetailType.d.cts +23 -0
- package/dist/api/api-schemas/productDetailType.d.cts.map +1 -0
- package/dist/api/api-schemas/productDetailType.d.ts +23 -0
- package/dist/api/api-schemas/productDetailType.d.ts.map +1 -0
- package/dist/api/api-schemas/productDetailType.js +9 -0
- package/dist/api/api-schemas/productDetailType.js.map +1 -0
- package/dist/api/api-schemas/productDmProjectTier.d.cts +24 -0
- package/dist/api/api-schemas/productDmProjectTier.d.cts.map +1 -0
- package/dist/api/api-schemas/productDmProjectTier.d.ts +24 -0
- package/dist/api/api-schemas/productDmProjectTier.d.ts.map +1 -0
- package/dist/api/api-schemas/productDmStorage.d.cts +20 -0
- package/dist/api/api-schemas/productDmStorage.d.cts.map +1 -0
- package/dist/api/api-schemas/productDmStorage.d.ts +20 -0
- package/dist/api/api-schemas/productDmStorage.d.ts.map +1 -0
- package/dist/api/api-schemas/productDmStorageDetail.d.cts +12 -0
- package/dist/api/api-schemas/productDmStorageDetail.d.cts.map +1 -0
- package/dist/api/api-schemas/productDmStorageDetail.d.ts +12 -0
- package/dist/api/api-schemas/productDmStorageDetail.d.ts.map +1 -0
- package/dist/api/api-schemas/productDmStorageDetailCoins.d.cts +20 -0
- package/dist/api/api-schemas/productDmStorageDetailCoins.d.cts.map +1 -0
- package/dist/api/api-schemas/productDmStorageDetailCoins.d.ts +20 -0
- package/dist/api/api-schemas/productDmStorageDetailCoins.d.ts.map +1 -0
- package/dist/api/api-schemas/productDmStorageDetailSize.d.cts +24 -0
- package/dist/api/api-schemas/productDmStorageDetailSize.d.cts.map +1 -0
- package/dist/api/api-schemas/productDmStorageDetailSize.d.ts +24 -0
- package/dist/api/api-schemas/productDmStorageDetailSize.d.ts.map +1 -0
- package/dist/api/api-schemas/productInstanceDetail.d.cts +10 -0
- package/dist/api/api-schemas/productInstanceDetail.d.cts.map +1 -0
- package/dist/api/api-schemas/productInstanceDetail.d.ts +10 -0
- package/dist/api/api-schemas/productInstanceDetail.d.ts.map +1 -0
- package/dist/api/api-schemas/productInstanceDetailCoins.d.cts +19 -0
- package/dist/api/api-schemas/productInstanceDetailCoins.d.cts.map +1 -0
- package/dist/api/api-schemas/productInstanceDetailCoins.d.ts +19 -0
- package/dist/api/api-schemas/productInstanceDetailCoins.d.ts.map +1 -0
- package/dist/api/api-schemas/productPatchBodyBody.d.cts +31 -0
- package/dist/api/api-schemas/productPatchBodyBody.d.cts.map +1 -0
- package/dist/api/api-schemas/productPatchBodyBody.d.ts +31 -0
- package/dist/api/api-schemas/productPatchBodyBody.d.ts.map +1 -0
- package/dist/api/api-schemas/productType.d.cts +15 -0
- package/dist/api/api-schemas/productType.d.cts.map +1 -0
- package/dist/api/api-schemas/productType.d.ts +15 -0
- package/dist/api/api-schemas/productType.d.ts.map +1 -0
- package/dist/api/api-schemas/productTypeServiceKind.cjs +7 -0
- package/dist/api/api-schemas/productTypeServiceKind.cjs.map +1 -0
- package/dist/api/api-schemas/productTypeServiceKind.d.cts +21 -0
- package/dist/api/api-schemas/productTypeServiceKind.d.cts.map +1 -0
- package/dist/api/api-schemas/productTypeServiceKind.d.ts +21 -0
- package/dist/api/api-schemas/productTypeServiceKind.d.ts.map +1 -0
- package/dist/api/api-schemas/productTypeServiceKind.js +6 -0
- package/dist/api/api-schemas/productTypeServiceKind.js.map +1 -0
- package/dist/api/api-schemas/productUnitGetResponse.d.cts +11 -0
- package/dist/api/api-schemas/productUnitGetResponse.d.cts.map +1 -0
- package/dist/api/api-schemas/productUnitGetResponse.d.ts +11 -0
- package/dist/api/api-schemas/productUnitGetResponse.d.ts.map +1 -0
- package/dist/api/api-schemas/productUnitGetResponseProduct.d.cts +12 -0
- package/dist/api/api-schemas/productUnitGetResponseProduct.d.cts.map +1 -0
- package/dist/api/api-schemas/productUnitGetResponseProduct.d.ts +12 -0
- package/dist/api/api-schemas/productUnitGetResponseProduct.d.ts.map +1 -0
- package/dist/api/api-schemas/productsGetDefaultStorageCost.d.cts +10 -0
- package/dist/api/api-schemas/productsGetDefaultStorageCost.d.cts.map +1 -0
- package/dist/api/api-schemas/productsGetDefaultStorageCost.d.ts +10 -0
- package/dist/api/api-schemas/productsGetDefaultStorageCost.d.ts.map +1 -0
- package/dist/api/api-schemas/productsGetDefaultStorageCostDefaultStorageCost.d.cts +19 -0
- package/dist/api/api-schemas/productsGetDefaultStorageCostDefaultStorageCost.d.cts.map +1 -0
- package/dist/api/api-schemas/productsGetDefaultStorageCostDefaultStorageCost.d.ts +19 -0
- package/dist/api/api-schemas/productsGetDefaultStorageCostDefaultStorageCost.d.ts.map +1 -0
- package/dist/api/api-schemas/productsGetResponse.d.cts +12 -0
- package/dist/api/api-schemas/productsGetResponse.d.cts.map +1 -0
- package/dist/api/api-schemas/productsGetResponse.d.ts +12 -0
- package/dist/api/api-schemas/productsGetResponse.d.ts.map +1 -0
- package/dist/api/api-schemas/productsGetResponseProductsItem.d.cts +9 -0
- package/dist/api/api-schemas/productsGetResponseProductsItem.d.cts.map +1 -0
- package/dist/api/api-schemas/productsGetResponseProductsItem.d.ts +9 -0
- package/dist/api/api-schemas/productsGetResponseProductsItem.d.ts.map +1 -0
- package/dist/api/api-schemas/productsGetTypesResponse.d.cts +13 -0
- package/dist/api/api-schemas/productsGetTypesResponse.d.cts.map +1 -0
- package/dist/api/api-schemas/productsGetTypesResponse.d.ts +13 -0
- package/dist/api/api-schemas/productsGetTypesResponse.d.ts.map +1 -0
- package/dist/api/api-schemas/qFormatParameter.cjs +10 -0
- package/dist/api/api-schemas/qFormatParameter.cjs.map +1 -0
- package/dist/api/api-schemas/qFormatParameter.d.cts +19 -0
- package/dist/api/api-schemas/qFormatParameter.d.cts.map +1 -0
- package/dist/api/api-schemas/qFormatParameter.d.ts +19 -0
- package/dist/api/api-schemas/qFormatParameter.d.ts.map +1 -0
- package/dist/api/api-schemas/qFormatParameter.js +9 -0
- package/dist/api/api-schemas/qFormatParameter.js.map +1 -0
- package/dist/api/api-schemas/qFromParameter.d.cts +18 -0
- package/dist/api/api-schemas/qFromParameter.d.cts.map +1 -0
- package/dist/api/api-schemas/qFromParameter.d.ts +18 -0
- package/dist/api/api-schemas/qFromParameter.d.ts.map +1 -0
- package/dist/api/api-schemas/qMIdParameter.d.cts +18 -0
- package/dist/api/api-schemas/qMIdParameter.d.cts.map +1 -0
- package/dist/api/api-schemas/qMIdParameter.d.ts +18 -0
- package/dist/api/api-schemas/qMIdParameter.d.ts.map +1 -0
- package/dist/api/api-schemas/qNameParameter.d.cts +18 -0
- package/dist/api/api-schemas/qNameParameter.d.cts.map +1 -0
- package/dist/api/api-schemas/qNameParameter.d.ts +18 -0
- package/dist/api/api-schemas/qNameParameter.d.ts.map +1 -0
- package/dist/api/api-schemas/qOrgIdParameter.d.cts +18 -0
- package/dist/api/api-schemas/qOrgIdParameter.d.cts.map +1 -0
- package/dist/api/api-schemas/qOrgIdParameter.d.ts +18 -0
- package/dist/api/api-schemas/qOrgIdParameter.d.ts.map +1 -0
- package/dist/api/api-schemas/qPbpParameter.d.cts +18 -0
- package/dist/api/api-schemas/qPbpParameter.d.cts.map +1 -0
- package/dist/api/api-schemas/qPbpParameter.d.ts +18 -0
- package/dist/api/api-schemas/qPbpParameter.d.ts.map +1 -0
- package/dist/api/api-schemas/qProductIdParameter.d.cts +18 -0
- package/dist/api/api-schemas/qProductIdParameter.d.cts.map +1 -0
- package/dist/api/api-schemas/qProductIdParameter.d.ts +18 -0
- package/dist/api/api-schemas/qProductIdParameter.d.ts.map +1 -0
- package/dist/api/api-schemas/qUnitIdParameter.d.cts +18 -0
- package/dist/api/api-schemas/qUnitIdParameter.d.cts.map +1 -0
- package/dist/api/api-schemas/qUnitIdParameter.d.ts +18 -0
- package/dist/api/api-schemas/qUnitIdParameter.d.ts.map +1 -0
- package/dist/api/api-schemas/qUntilParameter.d.cts +18 -0
- package/dist/api/api-schemas/qUntilParameter.d.cts.map +1 -0
- package/dist/api/api-schemas/qUntilParameter.d.ts +18 -0
- package/dist/api/api-schemas/qUntilParameter.d.ts.map +1 -0
- package/dist/api/api-schemas/qUserIdParameter.d.cts +18 -0
- package/dist/api/api-schemas/qUserIdParameter.d.cts.map +1 -0
- package/dist/api/api-schemas/qUserIdParameter.d.ts +18 -0
- package/dist/api/api-schemas/qUserIdParameter.d.ts.map +1 -0
- package/dist/api/api-schemas/stateGetVersionResponse.d.cts +19 -0
- package/dist/api/api-schemas/stateGetVersionResponse.d.cts.map +1 -0
- package/dist/api/api-schemas/stateGetVersionResponse.d.ts +19 -0
- package/dist/api/api-schemas/stateGetVersionResponse.d.ts.map +1 -0
- package/dist/api/api-schemas/storageChargeItem.d.cts +19 -0
- package/dist/api/api-schemas/storageChargeItem.d.cts.map +1 -0
- package/dist/api/api-schemas/storageChargeItem.d.ts +19 -0
- package/dist/api/api-schemas/storageChargeItem.d.ts.map +1 -0
- package/dist/api/api-schemas/storageCharges.d.cts +11 -0
- package/dist/api/api-schemas/storageCharges.d.cts.map +1 -0
- package/dist/api/api-schemas/storageCharges.d.ts +11 -0
- package/dist/api/api-schemas/storageCharges.d.ts.map +1 -0
- package/dist/api/api-schemas/unitAllDetail.d.cts +27 -0
- package/dist/api/api-schemas/unitAllDetail.d.cts.map +1 -0
- package/dist/api/api-schemas/unitAllDetail.d.ts +27 -0
- package/dist/api/api-schemas/unitAllDetail.d.ts.map +1 -0
- package/dist/api/api-schemas/unitAllDetailDefaultProductPrivacy.cjs +12 -0
- package/dist/api/api-schemas/unitAllDetailDefaultProductPrivacy.cjs.map +1 -0
- package/dist/api/api-schemas/unitAllDetailDefaultProductPrivacy.d.cts +24 -0
- package/dist/api/api-schemas/unitAllDetailDefaultProductPrivacy.d.cts.map +1 -0
- package/dist/api/api-schemas/unitAllDetailDefaultProductPrivacy.d.ts +24 -0
- package/dist/api/api-schemas/unitAllDetailDefaultProductPrivacy.d.ts.map +1 -0
- package/dist/api/api-schemas/unitAllDetailDefaultProductPrivacy.js +11 -0
- package/dist/api/api-schemas/unitAllDetailDefaultProductPrivacy.js.map +1 -0
- package/dist/api/api-schemas/unitChargeSummary.d.cts +10 -0
- package/dist/api/api-schemas/unitChargeSummary.d.cts.map +1 -0
- package/dist/api/api-schemas/unitChargeSummary.d.ts +10 -0
- package/dist/api/api-schemas/unitChargeSummary.d.ts.map +1 -0
- package/dist/api/api-schemas/unitChargesGetResponse.d.cts +32 -0
- package/dist/api/api-schemas/unitChargesGetResponse.d.cts.map +1 -0
- package/dist/api/api-schemas/unitChargesGetResponse.d.ts +32 -0
- package/dist/api/api-schemas/unitChargesGetResponse.d.ts.map +1 -0
- package/dist/api/api-schemas/unitDetail.d.cts +24 -0
- package/dist/api/api-schemas/unitDetail.d.cts.map +1 -0
- package/dist/api/api-schemas/unitDetail.d.ts +24 -0
- package/dist/api/api-schemas/unitDetail.d.ts.map +1 -0
- package/dist/api/api-schemas/unitDetailDefaultProductPrivacy.cjs +12 -0
- package/dist/api/api-schemas/unitDetailDefaultProductPrivacy.cjs.map +1 -0
- package/dist/api/api-schemas/unitDetailDefaultProductPrivacy.d.cts +24 -0
- package/dist/api/api-schemas/unitDetailDefaultProductPrivacy.d.cts.map +1 -0
- package/dist/api/api-schemas/unitDetailDefaultProductPrivacy.d.ts +24 -0
- package/dist/api/api-schemas/unitDetailDefaultProductPrivacy.d.ts.map +1 -0
- package/dist/api/api-schemas/unitDetailDefaultProductPrivacy.js +11 -0
- package/dist/api/api-schemas/unitDetailDefaultProductPrivacy.js.map +1 -0
- package/dist/api/api-schemas/unitGetResponse.d.cts +8 -0
- package/dist/api/api-schemas/unitGetResponse.d.cts.map +1 -0
- package/dist/api/api-schemas/unitGetResponse.d.ts +8 -0
- package/dist/api/api-schemas/unitGetResponse.d.ts.map +1 -0
- package/dist/api/api-schemas/unitPatchBodyBody.d.cts +14 -0
- package/dist/api/api-schemas/unitPatchBodyBody.d.cts.map +1 -0
- package/dist/api/api-schemas/unitPatchBodyBody.d.ts +14 -0
- package/dist/api/api-schemas/unitPatchBodyBody.d.ts.map +1 -0
- package/dist/api/api-schemas/unitPatchBodyBodyDefaultProductPrivacy.cjs +12 -0
- package/dist/api/api-schemas/unitPatchBodyBodyDefaultProductPrivacy.cjs.map +1 -0
- package/dist/api/api-schemas/unitPatchBodyBodyDefaultProductPrivacy.d.cts +26 -0
- package/dist/api/api-schemas/unitPatchBodyBodyDefaultProductPrivacy.d.cts.map +1 -0
- package/dist/api/api-schemas/unitPatchBodyBodyDefaultProductPrivacy.d.ts +26 -0
- package/dist/api/api-schemas/unitPatchBodyBodyDefaultProductPrivacy.d.ts.map +1 -0
- package/dist/api/api-schemas/unitPatchBodyBodyDefaultProductPrivacy.js +11 -0
- package/dist/api/api-schemas/unitPatchBodyBodyDefaultProductPrivacy.js.map +1 -0
- package/dist/api/api-schemas/unitProductChargeSummary.d.cts +12 -0
- package/dist/api/api-schemas/unitProductChargeSummary.d.cts.map +1 -0
- package/dist/api/api-schemas/unitProductChargeSummary.d.ts +12 -0
- package/dist/api/api-schemas/unitProductChargeSummary.d.ts.map +1 -0
- package/dist/api/api-schemas/unitProductPostBodyBody.d.cts +30 -0
- package/dist/api/api-schemas/unitProductPostBodyBody.d.cts.map +1 -0
- package/dist/api/api-schemas/unitProductPostBodyBody.d.ts +30 -0
- package/dist/api/api-schemas/unitProductPostBodyBody.d.ts.map +1 -0
- package/dist/api/api-schemas/unitProductPostBodyBodyFlavour.cjs +12 -0
- package/dist/api/api-schemas/unitProductPostBodyBodyFlavour.cjs.map +1 -0
- package/dist/api/api-schemas/unitProductPostBodyBodyFlavour.d.cts +24 -0
- package/dist/api/api-schemas/unitProductPostBodyBodyFlavour.d.cts.map +1 -0
- package/dist/api/api-schemas/unitProductPostBodyBodyFlavour.d.ts +24 -0
- package/dist/api/api-schemas/unitProductPostBodyBodyFlavour.d.ts.map +1 -0
- package/dist/api/api-schemas/unitProductPostBodyBodyFlavour.js +11 -0
- package/dist/api/api-schemas/unitProductPostBodyBodyFlavour.js.map +1 -0
- package/dist/api/api-schemas/unitProductPostBodyBodyType.cjs +10 -0
- package/dist/api/api-schemas/unitProductPostBodyBodyType.cjs.map +1 -0
- package/dist/api/api-schemas/unitProductPostBodyBodyType.d.cts +24 -0
- package/dist/api/api-schemas/unitProductPostBodyBodyType.d.cts.map +1 -0
- package/dist/api/api-schemas/unitProductPostBodyBodyType.d.ts +24 -0
- package/dist/api/api-schemas/unitProductPostBodyBodyType.d.ts.map +1 -0
- package/dist/api/api-schemas/unitProductPostBodyBodyType.js +9 -0
- package/dist/api/api-schemas/unitProductPostBodyBodyType.js.map +1 -0
- package/dist/api/api-schemas/unitProductPostResponse.d.cts +18 -0
- package/dist/api/api-schemas/unitProductPostResponse.d.cts.map +1 -0
- package/dist/api/api-schemas/unitProductPostResponse.d.ts +18 -0
- package/dist/api/api-schemas/unitProductPostResponse.d.ts.map +1 -0
- package/dist/api/api-schemas/unitsGetResponse.d.cts +12 -0
- package/dist/api/api-schemas/unitsGetResponse.d.cts.map +1 -0
- package/dist/api/api-schemas/unitsGetResponse.d.ts +12 -0
- package/dist/api/api-schemas/unitsGetResponse.d.ts.map +1 -0
- package/dist/api/api-schemas/userAccountDetail.d.cts +14 -0
- package/dist/api/api-schemas/userAccountDetail.d.cts.map +1 -0
- package/dist/api/api-schemas/userAccountDetail.d.ts +14 -0
- package/dist/api/api-schemas/userAccountDetail.d.ts.map +1 -0
- package/dist/api/api-schemas/userAccountGetResponse.d.cts +8 -0
- package/dist/api/api-schemas/userAccountGetResponse.d.cts.map +1 -0
- package/dist/api/api-schemas/userAccountGetResponse.d.ts +8 -0
- package/dist/api/api-schemas/userAccountGetResponse.d.ts.map +1 -0
- package/dist/api/api-schemas/userDetail.d.cts +18 -0
- package/dist/api/api-schemas/userDetail.d.cts.map +1 -0
- package/dist/api/api-schemas/userDetail.d.ts +18 -0
- package/dist/api/api-schemas/userDetail.d.ts.map +1 -0
- package/dist/api/api-schemas/usersGetResponse.d.cts +17 -0
- package/dist/api/api-schemas/usersGetResponse.d.cts.map +1 -0
- package/dist/api/api-schemas/usersGetResponse.d.ts +17 -0
- package/dist/api/api-schemas/usersGetResponse.d.ts.map +1 -0
- package/dist/api/asset/asset.cjs +114 -90
- package/dist/api/asset/asset.cjs.map +1 -1
- package/dist/api/asset/asset.d.cts +33 -17
- package/dist/api/asset/asset.d.cts.map +1 -1
- package/dist/api/asset/asset.d.ts +33 -17
- package/dist/api/asset/asset.d.ts.map +1 -1
- package/dist/api/asset/asset.fetch.cjs +478 -0
- package/dist/api/asset/asset.fetch.cjs.map +1 -0
- package/dist/api/asset/asset.fetch.d.cts +546 -0
- package/dist/api/asset/asset.fetch.d.cts.map +1 -0
- package/dist/api/asset/asset.fetch.d.ts +546 -0
- package/dist/api/asset/asset.fetch.d.ts.map +1 -0
- package/dist/api/asset/asset.fetch.js +434 -0
- package/dist/api/asset/asset.fetch.js.map +1 -0
- package/dist/api/asset/asset.js +93 -71
- package/dist/api/asset/asset.js.map +1 -1
- package/dist/api/charges/charges.cjs +122 -66
- package/dist/api/charges/charges.cjs.map +1 -1
- package/dist/api/charges/charges.d.cts +40 -16
- package/dist/api/charges/charges.d.cts.map +1 -1
- package/dist/api/charges/charges.d.ts +40 -16
- package/dist/api/charges/charges.d.ts.map +1 -1
- package/dist/api/charges/charges.fetch.cjs +347 -0
- package/dist/api/charges/charges.fetch.cjs.map +1 -0
- package/dist/api/charges/charges.fetch.d.cts +306 -0
- package/dist/api/charges/charges.fetch.d.cts.map +1 -0
- package/dist/api/charges/charges.fetch.d.ts +306 -0
- package/dist/api/charges/charges.fetch.d.ts.map +1 -0
- package/dist/api/charges/charges.fetch.js +315 -0
- package/dist/api/charges/charges.fetch.js.map +1 -0
- package/dist/api/charges/charges.js +107 -55
- package/dist/api/charges/charges.js.map +1 -1
- package/dist/api/event-stream/event-stream.cjs +69 -50
- package/dist/api/event-stream/event-stream.cjs.map +1 -1
- package/dist/api/event-stream/event-stream.d.cts +23 -12
- package/dist/api/event-stream/event-stream.d.cts.map +1 -1
- package/dist/api/event-stream/event-stream.d.ts +23 -12
- package/dist/api/event-stream/event-stream.d.ts.map +1 -1
- package/dist/api/event-stream/event-stream.fetch.cjs +249 -0
- package/dist/api/event-stream/event-stream.fetch.cjs.map +1 -0
- package/dist/api/event-stream/event-stream.fetch.d.cts +257 -0
- package/dist/api/event-stream/event-stream.fetch.d.cts.map +1 -0
- package/dist/api/event-stream/event-stream.fetch.d.ts +257 -0
- package/dist/api/event-stream/event-stream.fetch.d.ts.map +1 -0
- package/dist/api/event-stream/event-stream.fetch.js +225 -0
- package/dist/api/event-stream/event-stream.fetch.js.map +1 -0
- package/dist/api/event-stream/event-stream.js +58 -41
- package/dist/api/event-stream/event-stream.js.map +1 -1
- package/dist/api/merchant/merchant.cjs +54 -34
- package/dist/api/merchant/merchant.cjs.map +1 -1
- package/dist/api/merchant/merchant.d.cts +20 -10
- package/dist/api/merchant/merchant.d.cts.map +1 -1
- package/dist/api/merchant/merchant.d.ts +20 -10
- package/dist/api/merchant/merchant.d.ts.map +1 -1
- package/dist/api/merchant/merchant.fetch.cjs +165 -0
- package/dist/api/merchant/merchant.fetch.cjs.map +1 -0
- package/dist/api/merchant/merchant.fetch.d.cts +151 -0
- package/dist/api/merchant/merchant.fetch.d.cts.map +1 -0
- package/dist/api/merchant/merchant.fetch.d.ts +151 -0
- package/dist/api/merchant/merchant.fetch.d.ts.map +1 -0
- package/dist/api/merchant/merchant.fetch.js +149 -0
- package/dist/api/merchant/merchant.fetch.js.map +1 -0
- package/dist/api/merchant/merchant.js +47 -29
- package/dist/api/merchant/merchant.js.map +1 -1
- package/dist/api/organisation/organisation.cjs +110 -74
- package/dist/api/organisation/organisation.cjs.map +1 -1
- package/dist/api/organisation/organisation.d.cts +35 -16
- package/dist/api/organisation/organisation.d.cts.map +1 -1
- package/dist/api/organisation/organisation.d.ts +35 -16
- package/dist/api/organisation/organisation.d.ts.map +1 -1
- package/dist/api/organisation/organisation.fetch.cjs +379 -0
- package/dist/api/organisation/organisation.fetch.cjs.map +1 -0
- package/dist/api/organisation/organisation.fetch.d.cts +398 -0
- package/dist/api/organisation/organisation.fetch.d.cts.map +1 -0
- package/dist/api/organisation/organisation.fetch.d.ts +398 -0
- package/dist/api/organisation/organisation.fetch.d.ts.map +1 -0
- package/dist/api/organisation/organisation.fetch.js +343 -0
- package/dist/api/organisation/organisation.fetch.js.map +1 -0
- package/dist/api/organisation/organisation.js +93 -60
- package/dist/api/organisation/organisation.js.map +1 -1
- package/dist/api/product/product.cjs +188 -124
- package/dist/api/product/product.cjs.map +1 -1
- package/dist/api/product/product.d.cts +56 -25
- package/dist/api/product/product.d.cts.map +1 -1
- package/dist/api/product/product.d.ts +56 -25
- package/dist/api/product/product.d.ts.map +1 -1
- package/dist/api/product/product.fetch.cjs +591 -0
- package/dist/api/product/product.fetch.cjs.map +1 -0
- package/dist/api/product/product.fetch.d.cts +605 -0
- package/dist/api/product/product.fetch.d.cts.map +1 -0
- package/dist/api/product/product.fetch.d.ts +605 -0
- package/dist/api/product/product.fetch.d.ts.map +1 -0
- package/dist/api/product/product.fetch.js +531 -0
- package/dist/api/product/product.fetch.js.map +1 -0
- package/dist/api/product/product.js +159 -101
- package/dist/api/product/product.js.map +1 -1
- package/dist/api/state/state.cjs +25 -18
- package/dist/api/state/state.cjs.map +1 -1
- package/dist/api/state/state.d.cts +12 -7
- package/dist/api/state/state.d.cts.map +1 -1
- package/dist/api/state/state.d.ts +12 -7
- package/dist/api/state/state.d.ts.map +1 -1
- package/dist/api/state/state.fetch.cjs +89 -0
- package/dist/api/state/state.fetch.cjs.map +1 -0
- package/dist/api/state/state.fetch.d.cts +77 -0
- package/dist/api/state/state.fetch.d.cts.map +1 -0
- package/dist/api/state/state.fetch.d.ts +77 -0
- package/dist/api/state/state.fetch.d.ts.map +1 -0
- package/dist/api/state/state.fetch.js +81 -0
- package/dist/api/state/state.fetch.js.map +1 -0
- package/dist/api/state/state.js +22 -16
- package/dist/api/state/state.js.map +1 -1
- package/dist/api/unit/unit.cjs +169 -123
- package/dist/api/unit/unit.cjs.map +1 -1
- package/dist/api/unit/unit.d.cts +48 -23
- package/dist/api/unit/unit.d.cts.map +1 -1
- package/dist/api/unit/unit.d.ts +48 -23
- package/dist/api/unit/unit.d.ts.map +1 -1
- package/dist/api/unit/unit.fetch.cjs +620 -0
- package/dist/api/unit/unit.fetch.cjs.map +1 -0
- package/dist/api/unit/unit.fetch.d.cts +665 -0
- package/dist/api/unit/unit.fetch.d.cts.map +1 -0
- package/dist/api/unit/unit.fetch.d.ts +665 -0
- package/dist/api/unit/unit.fetch.d.ts.map +1 -0
- package/dist/api/unit/unit.fetch.js +560 -0
- package/dist/api/unit/unit.fetch.js.map +1 -0
- package/dist/api/unit/unit.js +140 -98
- package/dist/api/unit/unit.js.map +1 -1
- package/dist/api/user/user.cjs +121 -82
- package/dist/api/user/user.cjs.map +1 -1
- package/dist/api/user/user.d.cts +31 -17
- package/dist/api/user/user.d.cts.map +1 -1
- package/dist/api/user/user.d.ts +31 -17
- package/dist/api/user/user.d.ts.map +1 -1
- package/dist/api/user/user.fetch.cjs +407 -0
- package/dist/api/user/user.fetch.cjs.map +1 -0
- package/dist/api/user/user.fetch.d.cts +454 -0
- package/dist/api/user/user.fetch.d.cts.map +1 -0
- package/dist/api/user/user.fetch.d.ts +454 -0
- package/dist/api/user/user.fetch.d.ts.map +1 -0
- package/dist/api/user/user.fetch.js +367 -0
- package/dist/api/user/user.fetch.js.map +1 -0
- package/dist/api/user/user.js +102 -66
- package/dist/api/user/user.js.map +1 -1
- package/dist/{custom-instance.cjs → custom-axios.cjs} +6 -14
- package/dist/custom-axios.cjs.map +1 -0
- package/dist/{custom-instance.d.ts → custom-axios.d.cts} +2 -2
- package/dist/custom-axios.d.cts.map +1 -0
- package/dist/{custom-instance.d.cts → custom-axios.d.ts} +2 -2
- package/dist/custom-axios.d.ts.map +1 -0
- package/dist/{custom-instance.js → custom-axios.js} +6 -14
- package/dist/custom-axios.js.map +1 -0
- package/dist/custom-fetch.cjs +32 -0
- package/dist/custom-fetch.cjs.map +1 -0
- package/dist/custom-fetch.d.cts +13 -0
- package/dist/custom-fetch.d.cts.map +1 -0
- package/dist/custom-fetch.d.ts +13 -0
- package/dist/custom-fetch.d.ts.map +1 -0
- package/dist/custom-fetch.js +31 -0
- package/dist/custom-fetch.js.map +1 -0
- package/dist/index.cjs +53 -30
- package/dist/index.d.cts +118 -2
- package/dist/index.d.ts +118 -2
- package/dist/index.js +25 -2
- package/morph-query-keys.ts +57 -0
- package/orval.config.ts +46 -7
- package/package.json +256 -3
- package/src/api/actions/actions.fetch.ts +188 -0
- package/src/api/actions/actions.ts +29 -17
- package/src/api/api-schemas/actionDetail.ts +22 -0
- package/src/api/api-schemas/actionGetResponse.ts +20 -0
- package/src/api/api-schemas/asError.ts +15 -0
- package/src/api/api-schemas/assetDetail.ts +27 -0
- package/src/api/api-schemas/assetDetailScope.ts +21 -0
- package/src/api/api-schemas/assetGetByIdResponse.ts +13 -0
- package/src/api/api-schemas/assetGetResponse.ts +20 -0
- package/src/api/api-schemas/assetPatchBodyBody.ts +19 -0
- package/src/api/api-schemas/assetPostBodyBody.ts +32 -0
- package/src/api/api-schemas/assetPostBodyBodyScope.ts +25 -0
- package/src/api/api-schemas/assetPostResponse.ts +16 -0
- package/src/api/api-schemas/attachAssetParams.ts +19 -0
- package/src/api/api-schemas/chargeAdditionalData.ts +14 -0
- package/src/api/api-schemas/chargeSummary.ts +18 -0
- package/src/api/api-schemas/chargeSummaryType.ts +18 -0
- package/src/api/api-schemas/chargesGetResponse.ts +19 -0
- package/src/api/api-schemas/detachAssetParams.ts +19 -0
- package/src/api/api-schemas/eventStreamGetPostResponse.ts +21 -0
- package/src/api/api-schemas/eventStreamPostBodyBody.ts +13 -0
- package/src/api/api-schemas/eventStreamPostBodyBodyFormat.ts +19 -0
- package/src/api/api-schemas/eventStreamVersionGetResponse.ts +20 -0
- package/src/api/api-schemas/eventStreamVersionGetResponseProtocol.ts +23 -0
- package/src/api/api-schemas/getActionsParams.ts +52 -0
- package/src/api/api-schemas/getAssetParams.ts +39 -0
- package/src/api/api-schemas/getChargesParams.ts +30 -0
- package/src/api/api-schemas/getOrganisationChargesParams.ts +30 -0
- package/src/api/api-schemas/getOrganisationsParams.ts +18 -0
- package/src/api/api-schemas/getProductChargesParams.ts +30 -0
- package/src/api/api-schemas/getUnitChargesParams.ts +30 -0
- package/src/api/api-schemas/getUnitsParams.ts +18 -0
- package/src/api/api-schemas/index.ts +128 -0
- package/src/api/api-schemas/merchantDetail.ts +23 -0
- package/src/api/api-schemas/merchantDetailKind.ts +18 -0
- package/src/api/api-schemas/merchantGetResponse.ts +13 -0
- package/src/api/api-schemas/merchantSummary.ts +20 -0
- package/src/api/api-schemas/merchantSummaryKind.ts +18 -0
- package/src/api/api-schemas/merchantsGetResponse.ts +18 -0
- package/src/api/api-schemas/organisationAllDetail.ts +30 -0
- package/src/api/api-schemas/organisationAllDetailDefaultProductPrivacy.ts +24 -0
- package/src/api/api-schemas/organisationChargeSummary.ts +17 -0
- package/src/api/api-schemas/organisationChargesGetResponse.ts +20 -0
- package/src/api/api-schemas/organisationDetail.ts +27 -0
- package/src/api/api-schemas/organisationDetailDefaultProductPrivacy.ts +24 -0
- package/src/api/api-schemas/organisationGetDefaultResponse.ts +28 -0
- package/src/api/api-schemas/organisationGetDefaultResponseDefaultProductPrivacy.ts +24 -0
- package/src/api/api-schemas/organisationGetResponse.ts +13 -0
- package/src/api/api-schemas/organisationPatchBodyBody.ts +20 -0
- package/src/api/api-schemas/organisationPatchBodyBodyDefaultProductPrivacy.ts +26 -0
- package/src/api/api-schemas/organisationPostBodyBody.ts +23 -0
- package/src/api/api-schemas/organisationPostBodyBodyDefaultProductPrivacy.ts +24 -0
- package/src/api/api-schemas/organisationPostResponse.ts +15 -0
- package/src/api/api-schemas/organisationUnitChargeSummary.ts +26 -0
- package/src/api/api-schemas/organisationUnitPostBodyBody.ts +27 -0
- package/src/api/api-schemas/organisationUnitPostBodyBodyDefaultProductPrivacy.ts +24 -0
- package/src/api/api-schemas/organisationUnitPostResponse.ts +15 -0
- package/src/api/api-schemas/organisationUnitsGetResponse.ts +20 -0
- package/src/api/api-schemas/organisationsGetResponse.ts +17 -0
- package/src/api/api-schemas/personalUnitPutBodyBody.ts +19 -0
- package/src/api/api-schemas/personalUnitPutResponse.ts +17 -0
- package/src/api/api-schemas/processingChargeItem.ts +25 -0
- package/src/api/api-schemas/processingCharges.ts +25 -0
- package/src/api/api-schemas/processingChargesMerchantKind.ts +16 -0
- package/src/api/api-schemas/productChargesGetResponse.ts +36 -0
- package/src/api/api-schemas/productChargesGetResponseProductType.ts +19 -0
- package/src/api/api-schemas/productClaimDetail.ts +19 -0
- package/src/api/api-schemas/productCoinsDetail.ts +35 -0
- package/src/api/api-schemas/productDetail.ts +28 -0
- package/src/api/api-schemas/productDetailFlavour.ts +24 -0
- package/src/api/api-schemas/productDetailType.ts +22 -0
- package/src/api/api-schemas/productDmProjectTier.ts +29 -0
- package/src/api/api-schemas/productDmStorage.ts +25 -0
- package/src/api/api-schemas/productDmStorageDetail.ts +17 -0
- package/src/api/api-schemas/productDmStorageDetailCoins.ts +17 -0
- package/src/api/api-schemas/productDmStorageDetailSize.ts +21 -0
- package/src/api/api-schemas/productInstanceDetail.ts +15 -0
- package/src/api/api-schemas/productInstanceDetailCoins.ts +16 -0
- package/src/api/api-schemas/productPatchBodyBody.ts +28 -0
- package/src/api/api-schemas/productType.ts +20 -0
- package/src/api/api-schemas/productTypeServiceKind.ts +19 -0
- package/src/api/api-schemas/productUnitGetResponse.ts +16 -0
- package/src/api/api-schemas/productUnitGetResponseProduct.ts +17 -0
- package/src/api/api-schemas/productsGetDefaultStorageCost.ts +15 -0
- package/src/api/api-schemas/productsGetDefaultStorageCostDefaultStorageCost.ts +16 -0
- package/src/api/api-schemas/productsGetResponse.ts +17 -0
- package/src/api/api-schemas/productsGetResponseProductsItem.ts +14 -0
- package/src/api/api-schemas/productsGetTypesResponse.ts +18 -0
- package/src/api/api-schemas/qFormatParameter.ts +18 -0
- package/src/api/api-schemas/qFromParameter.ts +15 -0
- package/src/api/api-schemas/qMIdParameter.ts +15 -0
- package/src/api/api-schemas/qNameParameter.ts +15 -0
- package/src/api/api-schemas/qOrgIdParameter.ts +15 -0
- package/src/api/api-schemas/qPbpParameter.ts +15 -0
- package/src/api/api-schemas/qProductIdParameter.ts +15 -0
- package/src/api/api-schemas/qUnitIdParameter.ts +15 -0
- package/src/api/api-schemas/qUntilParameter.ts +15 -0
- package/src/api/api-schemas/qUserIdParameter.ts +15 -0
- package/src/api/api-schemas/stateGetVersionResponse.ts +16 -0
- package/src/api/api-schemas/storageChargeItem.ts +24 -0
- package/src/api/api-schemas/storageCharges.ts +16 -0
- package/src/api/api-schemas/unitAllDetail.ts +32 -0
- package/src/api/api-schemas/unitAllDetailDefaultProductPrivacy.ts +24 -0
- package/src/api/api-schemas/unitChargeSummary.ts +15 -0
- package/src/api/api-schemas/unitChargesGetResponse.ts +37 -0
- package/src/api/api-schemas/unitDetail.ts +29 -0
- package/src/api/api-schemas/unitDetailDefaultProductPrivacy.ts +24 -0
- package/src/api/api-schemas/unitGetResponse.ts +13 -0
- package/src/api/api-schemas/unitPatchBodyBody.ts +20 -0
- package/src/api/api-schemas/unitPatchBodyBodyDefaultProductPrivacy.ts +26 -0
- package/src/api/api-schemas/unitProductChargeSummary.ts +17 -0
- package/src/api/api-schemas/unitProductPostBodyBody.ts +36 -0
- package/src/api/api-schemas/unitProductPostBodyBodyFlavour.ts +24 -0
- package/src/api/api-schemas/unitProductPostBodyBodyType.ts +24 -0
- package/src/api/api-schemas/unitProductPostResponse.ts +15 -0
- package/src/api/api-schemas/unitsGetResponse.ts +17 -0
- package/src/api/api-schemas/userAccountDetail.ts +19 -0
- package/src/api/api-schemas/userAccountGetResponse.ts +13 -0
- package/src/api/api-schemas/userDetail.ts +15 -0
- package/src/api/api-schemas/usersGetResponse.ts +22 -0
- package/src/api/asset/asset.fetch.ts +1119 -0
- package/src/api/asset/asset.ts +70 -64
- package/src/api/charges/charges.fetch.ts +777 -0
- package/src/api/charges/charges.ts +101 -50
- package/src/api/event-stream/event-stream.fetch.ts +539 -0
- package/src/api/event-stream/event-stream.ts +49 -37
- package/src/api/merchant/merchant.fetch.ts +318 -0
- package/src/api/merchant/merchant.ts +48 -28
- package/src/api/organisation/organisation.fetch.ts +863 -0
- package/src/api/organisation/organisation.ts +73 -53
- package/src/api/product/product.fetch.ts +1292 -0
- package/src/api/product/product.ts +141 -88
- package/src/api/state/state.fetch.ts +162 -0
- package/src/api/state/state.ts +28 -17
- package/src/api/unit/unit.fetch.ts +1394 -0
- package/src/api/unit/unit.ts +116 -88
- package/src/api/user/user.fetch.ts +965 -0
- package/src/api/user/user.ts +82 -58
- package/src/{custom-instance.ts → custom-axios.ts} +1 -14
- package/src/custom-fetch.ts +59 -0
- package/src/index.ts +2 -2
- package/tsdown.config.ts +35 -4
- package/dist/api/api.schemas.cjs +0 -142
- package/dist/api/api.schemas.cjs.map +0 -1
- package/dist/api/api.schemas.d.cts +0 -1032
- package/dist/api/api.schemas.d.cts.map +0 -1
- package/dist/api/api.schemas.d.ts +0 -1032
- package/dist/api/api.schemas.d.ts.map +0 -1
- package/dist/api/api.schemas.js +0 -118
- package/dist/api/api.schemas.js.map +0 -1
- package/dist/custom-instance.cjs.map +0 -1
- package/dist/custom-instance.d.cts.map +0 -1
- package/dist/custom-instance.d.ts.map +0 -1
- package/dist/custom-instance.js.map +0 -1
- package/dist/options-mutator.cjs +0 -24
- package/dist/options-mutator.cjs.map +0 -1
- package/dist/options-mutator.js +0 -23
- package/dist/options-mutator.js.map +0 -1
- package/src/api/api.schemas.ts +0 -1199
- package/src/options-mutator.ts +0 -27
package/dist/api/user/user.js
CHANGED
|
@@ -1,5 +1,4 @@
|
|
|
1
|
-
import { customInstance } from "../../custom-
|
|
2
|
-
import { mutationMutator, queryMutator } from "../../options-mutator.js";
|
|
1
|
+
import { customInstance } from "../../custom-axios.js";
|
|
3
2
|
import { useMutation, useQuery, useSuspenseQuery } from "@tanstack/react-query";
|
|
4
3
|
|
|
5
4
|
//#region src/api/user/user.ts
|
|
@@ -26,42 +25,53 @@ const getUserAccount = (options, signal) => {
|
|
|
26
25
|
}, options);
|
|
27
26
|
};
|
|
28
27
|
const getGetUserAccountQueryKey = () => {
|
|
29
|
-
return [
|
|
28
|
+
return [
|
|
29
|
+
"account-server",
|
|
30
|
+
"user",
|
|
31
|
+
"account"
|
|
32
|
+
];
|
|
30
33
|
};
|
|
31
|
-
const
|
|
34
|
+
const getGetUserAccountQueryOptions = (options) => {
|
|
32
35
|
const { query: queryOptions, request: requestOptions } = options ?? {};
|
|
33
36
|
const queryKey = queryOptions?.queryKey ?? getGetUserAccountQueryKey();
|
|
34
37
|
const queryFn = ({ signal }) => getUserAccount(requestOptions, signal);
|
|
35
|
-
return
|
|
36
|
-
...queryOptions,
|
|
38
|
+
return {
|
|
37
39
|
queryKey,
|
|
38
|
-
queryFn
|
|
39
|
-
|
|
40
|
+
queryFn,
|
|
41
|
+
...queryOptions
|
|
42
|
+
};
|
|
40
43
|
};
|
|
41
44
|
/**
|
|
42
45
|
* @summary Get information about your account
|
|
43
46
|
*/
|
|
44
47
|
function useGetUserAccount(options) {
|
|
45
|
-
const queryOptions =
|
|
48
|
+
const queryOptions = getGetUserAccountQueryOptions(options);
|
|
46
49
|
const query = useQuery(queryOptions);
|
|
47
50
|
query.queryKey = queryOptions.queryKey;
|
|
48
51
|
return query;
|
|
49
52
|
}
|
|
50
|
-
|
|
53
|
+
/**
|
|
54
|
+
* @summary Get information about your account
|
|
55
|
+
*/
|
|
56
|
+
const invalidateGetUserAccount = async (queryClient, options) => {
|
|
57
|
+
await queryClient.invalidateQueries({ queryKey: getGetUserAccountQueryKey() }, options);
|
|
58
|
+
return queryClient;
|
|
59
|
+
};
|
|
60
|
+
const getGetUserAccountSuspenseQueryOptions = (options) => {
|
|
51
61
|
const { query: queryOptions, request: requestOptions } = options ?? {};
|
|
52
62
|
const queryKey = queryOptions?.queryKey ?? getGetUserAccountQueryKey();
|
|
53
63
|
const queryFn = ({ signal }) => getUserAccount(requestOptions, signal);
|
|
54
|
-
return
|
|
55
|
-
...queryOptions,
|
|
64
|
+
return {
|
|
56
65
|
queryKey,
|
|
57
|
-
queryFn
|
|
58
|
-
|
|
66
|
+
queryFn,
|
|
67
|
+
...queryOptions
|
|
68
|
+
};
|
|
59
69
|
};
|
|
60
70
|
/**
|
|
61
71
|
* @summary Get information about your account
|
|
62
72
|
*/
|
|
63
73
|
function useGetUserAccountSuspense(options) {
|
|
64
|
-
const queryOptions =
|
|
74
|
+
const queryOptions = getGetUserAccountSuspenseQueryOptions(options);
|
|
65
75
|
const query = useSuspenseQuery(queryOptions);
|
|
66
76
|
query.queryKey = queryOptions.queryKey;
|
|
67
77
|
return query;
|
|
@@ -83,42 +93,55 @@ const getOrganisationUsers = (orgId, options, signal) => {
|
|
|
83
93
|
}, options);
|
|
84
94
|
};
|
|
85
95
|
const getGetOrganisationUsersQueryKey = (orgId) => {
|
|
86
|
-
return [
|
|
96
|
+
return [
|
|
97
|
+
"account-server",
|
|
98
|
+
"organisation",
|
|
99
|
+
orgId,
|
|
100
|
+
"user"
|
|
101
|
+
];
|
|
87
102
|
};
|
|
88
|
-
const
|
|
103
|
+
const getGetOrganisationUsersQueryOptions = (orgId, options) => {
|
|
89
104
|
const { query: queryOptions, request: requestOptions } = options ?? {};
|
|
90
105
|
const queryKey = queryOptions?.queryKey ?? getGetOrganisationUsersQueryKey(orgId);
|
|
91
106
|
const queryFn = ({ signal }) => getOrganisationUsers(orgId, requestOptions, signal);
|
|
92
|
-
return
|
|
93
|
-
...queryOptions,
|
|
107
|
+
return {
|
|
94
108
|
queryKey,
|
|
95
|
-
queryFn
|
|
96
|
-
|
|
109
|
+
queryFn,
|
|
110
|
+
enabled: !!orgId,
|
|
111
|
+
...queryOptions
|
|
112
|
+
};
|
|
97
113
|
};
|
|
98
114
|
/**
|
|
99
115
|
* @summary Gets users in an Organisation
|
|
100
116
|
*/
|
|
101
117
|
function useGetOrganisationUsers(orgId, options) {
|
|
102
|
-
const queryOptions =
|
|
118
|
+
const queryOptions = getGetOrganisationUsersQueryOptions(orgId, options);
|
|
103
119
|
const query = useQuery(queryOptions);
|
|
104
120
|
query.queryKey = queryOptions.queryKey;
|
|
105
121
|
return query;
|
|
106
122
|
}
|
|
107
|
-
|
|
123
|
+
/**
|
|
124
|
+
* @summary Gets users in an Organisation
|
|
125
|
+
*/
|
|
126
|
+
const invalidateGetOrganisationUsers = async (queryClient, orgId, options) => {
|
|
127
|
+
await queryClient.invalidateQueries({ queryKey: getGetOrganisationUsersQueryKey(orgId) }, options);
|
|
128
|
+
return queryClient;
|
|
129
|
+
};
|
|
130
|
+
const getGetOrganisationUsersSuspenseQueryOptions = (orgId, options) => {
|
|
108
131
|
const { query: queryOptions, request: requestOptions } = options ?? {};
|
|
109
132
|
const queryKey = queryOptions?.queryKey ?? getGetOrganisationUsersQueryKey(orgId);
|
|
110
133
|
const queryFn = ({ signal }) => getOrganisationUsers(orgId, requestOptions, signal);
|
|
111
|
-
return
|
|
112
|
-
...queryOptions,
|
|
134
|
+
return {
|
|
113
135
|
queryKey,
|
|
114
|
-
queryFn
|
|
115
|
-
|
|
136
|
+
queryFn,
|
|
137
|
+
...queryOptions
|
|
138
|
+
};
|
|
116
139
|
};
|
|
117
140
|
/**
|
|
118
141
|
* @summary Gets users in an Organisation
|
|
119
142
|
*/
|
|
120
143
|
function useGetOrganisationUsersSuspense(orgId, options) {
|
|
121
|
-
const queryOptions =
|
|
144
|
+
const queryOptions = getGetOrganisationUsersSuspenseQueryOptions(orgId, options);
|
|
122
145
|
const query = useSuspenseQuery(queryOptions);
|
|
123
146
|
query.queryKey = queryOptions.queryKey;
|
|
124
147
|
return query;
|
|
@@ -136,7 +159,7 @@ const addOrganisationUser = (orgId, userId, options) => {
|
|
|
136
159
|
method: "PUT"
|
|
137
160
|
}, options);
|
|
138
161
|
};
|
|
139
|
-
const
|
|
162
|
+
const getAddOrganisationUserMutationOptions = (options) => {
|
|
140
163
|
const mutationKey = ["addOrganisationUser"];
|
|
141
164
|
const { mutation: mutationOptions, request: requestOptions } = options ? options.mutation && "mutationKey" in options.mutation && options.mutation.mutationKey ? options : {
|
|
142
165
|
...options,
|
|
@@ -152,16 +175,16 @@ const useAddOrganisationUserMutationOptions = (options) => {
|
|
|
152
175
|
const { orgId, userId } = props ?? {};
|
|
153
176
|
return addOrganisationUser(orgId, userId, requestOptions);
|
|
154
177
|
};
|
|
155
|
-
return
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
}
|
|
178
|
+
return {
|
|
179
|
+
mutationFn,
|
|
180
|
+
...mutationOptions
|
|
181
|
+
};
|
|
159
182
|
};
|
|
160
183
|
/**
|
|
161
184
|
* @summary Adds a User to an Organisation
|
|
162
185
|
*/
|
|
163
186
|
const useAddOrganisationUser = (options) => {
|
|
164
|
-
return useMutation(
|
|
187
|
+
return useMutation(getAddOrganisationUserMutationOptions(options));
|
|
165
188
|
};
|
|
166
189
|
/**
|
|
167
190
|
* Removes a User from an **Organisation**.
|
|
@@ -176,7 +199,7 @@ const deleteOrganisationUser = (orgId, userId, options) => {
|
|
|
176
199
|
method: "DELETE"
|
|
177
200
|
}, options);
|
|
178
201
|
};
|
|
179
|
-
const
|
|
202
|
+
const getDeleteOrganisationUserMutationOptions = (options) => {
|
|
180
203
|
const mutationKey = ["deleteOrganisationUser"];
|
|
181
204
|
const { mutation: mutationOptions, request: requestOptions } = options ? options.mutation && "mutationKey" in options.mutation && options.mutation.mutationKey ? options : {
|
|
182
205
|
...options,
|
|
@@ -192,16 +215,16 @@ const useDeleteOrganisationUserMutationOptions = (options) => {
|
|
|
192
215
|
const { orgId, userId } = props ?? {};
|
|
193
216
|
return deleteOrganisationUser(orgId, userId, requestOptions);
|
|
194
217
|
};
|
|
195
|
-
return
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
}
|
|
218
|
+
return {
|
|
219
|
+
mutationFn,
|
|
220
|
+
...mutationOptions
|
|
221
|
+
};
|
|
199
222
|
};
|
|
200
223
|
/**
|
|
201
224
|
* @summary Deletes a User from an Organisation
|
|
202
225
|
*/
|
|
203
226
|
const useDeleteOrganisationUser = (options) => {
|
|
204
|
-
return useMutation(
|
|
227
|
+
return useMutation(getDeleteOrganisationUserMutationOptions(options));
|
|
205
228
|
};
|
|
206
229
|
/**
|
|
207
230
|
* Gets users in an Organisational Unit.
|
|
@@ -220,42 +243,55 @@ const getOrganisationUnitUsers = (unitId, options, signal) => {
|
|
|
220
243
|
}, options);
|
|
221
244
|
};
|
|
222
245
|
const getGetOrganisationUnitUsersQueryKey = (unitId) => {
|
|
223
|
-
return [
|
|
246
|
+
return [
|
|
247
|
+
"account-server",
|
|
248
|
+
"unit",
|
|
249
|
+
unitId,
|
|
250
|
+
"user"
|
|
251
|
+
];
|
|
224
252
|
};
|
|
225
|
-
const
|
|
253
|
+
const getGetOrganisationUnitUsersQueryOptions = (unitId, options) => {
|
|
226
254
|
const { query: queryOptions, request: requestOptions } = options ?? {};
|
|
227
255
|
const queryKey = queryOptions?.queryKey ?? getGetOrganisationUnitUsersQueryKey(unitId);
|
|
228
256
|
const queryFn = ({ signal }) => getOrganisationUnitUsers(unitId, requestOptions, signal);
|
|
229
|
-
return
|
|
230
|
-
...queryOptions,
|
|
257
|
+
return {
|
|
231
258
|
queryKey,
|
|
232
|
-
queryFn
|
|
233
|
-
|
|
259
|
+
queryFn,
|
|
260
|
+
enabled: !!unitId,
|
|
261
|
+
...queryOptions
|
|
262
|
+
};
|
|
234
263
|
};
|
|
235
264
|
/**
|
|
236
265
|
* @summary Gets users in an Organisational Unit
|
|
237
266
|
*/
|
|
238
267
|
function useGetOrganisationUnitUsers(unitId, options) {
|
|
239
|
-
const queryOptions =
|
|
268
|
+
const queryOptions = getGetOrganisationUnitUsersQueryOptions(unitId, options);
|
|
240
269
|
const query = useQuery(queryOptions);
|
|
241
270
|
query.queryKey = queryOptions.queryKey;
|
|
242
271
|
return query;
|
|
243
272
|
}
|
|
244
|
-
|
|
273
|
+
/**
|
|
274
|
+
* @summary Gets users in an Organisational Unit
|
|
275
|
+
*/
|
|
276
|
+
const invalidateGetOrganisationUnitUsers = async (queryClient, unitId, options) => {
|
|
277
|
+
await queryClient.invalidateQueries({ queryKey: getGetOrganisationUnitUsersQueryKey(unitId) }, options);
|
|
278
|
+
return queryClient;
|
|
279
|
+
};
|
|
280
|
+
const getGetOrganisationUnitUsersSuspenseQueryOptions = (unitId, options) => {
|
|
245
281
|
const { query: queryOptions, request: requestOptions } = options ?? {};
|
|
246
282
|
const queryKey = queryOptions?.queryKey ?? getGetOrganisationUnitUsersQueryKey(unitId);
|
|
247
283
|
const queryFn = ({ signal }) => getOrganisationUnitUsers(unitId, requestOptions, signal);
|
|
248
|
-
return
|
|
249
|
-
...queryOptions,
|
|
284
|
+
return {
|
|
250
285
|
queryKey,
|
|
251
|
-
queryFn
|
|
252
|
-
|
|
286
|
+
queryFn,
|
|
287
|
+
...queryOptions
|
|
288
|
+
};
|
|
253
289
|
};
|
|
254
290
|
/**
|
|
255
291
|
* @summary Gets users in an Organisational Unit
|
|
256
292
|
*/
|
|
257
293
|
function useGetOrganisationUnitUsersSuspense(unitId, options) {
|
|
258
|
-
const queryOptions =
|
|
294
|
+
const queryOptions = getGetOrganisationUnitUsersSuspenseQueryOptions(unitId, options);
|
|
259
295
|
const query = useSuspenseQuery(queryOptions);
|
|
260
296
|
query.queryKey = queryOptions.queryKey;
|
|
261
297
|
return query;
|
|
@@ -275,7 +311,7 @@ const addOrganisationUnitUser = (unitId, userId, options) => {
|
|
|
275
311
|
method: "PUT"
|
|
276
312
|
}, options);
|
|
277
313
|
};
|
|
278
|
-
const
|
|
314
|
+
const getAddOrganisationUnitUserMutationOptions = (options) => {
|
|
279
315
|
const mutationKey = ["addOrganisationUnitUser"];
|
|
280
316
|
const { mutation: mutationOptions, request: requestOptions } = options ? options.mutation && "mutationKey" in options.mutation && options.mutation.mutationKey ? options : {
|
|
281
317
|
...options,
|
|
@@ -291,16 +327,16 @@ const useAddOrganisationUnitUserMutationOptions = (options) => {
|
|
|
291
327
|
const { unitId, userId } = props ?? {};
|
|
292
328
|
return addOrganisationUnitUser(unitId, userId, requestOptions);
|
|
293
329
|
};
|
|
294
|
-
return
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
}
|
|
330
|
+
return {
|
|
331
|
+
mutationFn,
|
|
332
|
+
...mutationOptions
|
|
333
|
+
};
|
|
298
334
|
};
|
|
299
335
|
/**
|
|
300
336
|
* @summary Adds a user to an Organisational Unit
|
|
301
337
|
*/
|
|
302
338
|
const useAddOrganisationUnitUser = (options) => {
|
|
303
|
-
return useMutation(
|
|
339
|
+
return useMutation(getAddOrganisationUnitUserMutationOptions(options));
|
|
304
340
|
};
|
|
305
341
|
/**
|
|
306
342
|
* Removes a User from an Organisational Unit.
|
|
@@ -317,7 +353,7 @@ const deleteOrganisationUnitUser = (unitId, userId, options) => {
|
|
|
317
353
|
method: "DELETE"
|
|
318
354
|
}, options);
|
|
319
355
|
};
|
|
320
|
-
const
|
|
356
|
+
const getDeleteOrganisationUnitUserMutationOptions = (options) => {
|
|
321
357
|
const mutationKey = ["deleteOrganisationUnitUser"];
|
|
322
358
|
const { mutation: mutationOptions, request: requestOptions } = options ? options.mutation && "mutationKey" in options.mutation && options.mutation.mutationKey ? options : {
|
|
323
359
|
...options,
|
|
@@ -333,18 +369,18 @@ const useDeleteOrganisationUnitUserMutationOptions = (options) => {
|
|
|
333
369
|
const { unitId, userId } = props ?? {};
|
|
334
370
|
return deleteOrganisationUnitUser(unitId, userId, requestOptions);
|
|
335
371
|
};
|
|
336
|
-
return
|
|
337
|
-
|
|
338
|
-
|
|
339
|
-
}
|
|
372
|
+
return {
|
|
373
|
+
mutationFn,
|
|
374
|
+
...mutationOptions
|
|
375
|
+
};
|
|
340
376
|
};
|
|
341
377
|
/**
|
|
342
378
|
* @summary Deletes a User from an Organisational Unit
|
|
343
379
|
*/
|
|
344
380
|
const useDeleteOrganisationUnitUser = (options) => {
|
|
345
|
-
return useMutation(
|
|
381
|
+
return useMutation(getDeleteOrganisationUnitUserMutationOptions(options));
|
|
346
382
|
};
|
|
347
383
|
|
|
348
384
|
//#endregion
|
|
349
|
-
export { addOrganisationUnitUser, addOrganisationUser, deleteOrganisationUnitUser, deleteOrganisationUser, getGetOrganisationUnitUsersQueryKey,
|
|
385
|
+
export { addOrganisationUnitUser, addOrganisationUser, deleteOrganisationUnitUser, deleteOrganisationUser, getAddOrganisationUnitUserMutationOptions, getAddOrganisationUserMutationOptions, getDeleteOrganisationUnitUserMutationOptions, getDeleteOrganisationUserMutationOptions, getGetOrganisationUnitUsersQueryKey, getGetOrganisationUnitUsersQueryOptions, getGetOrganisationUnitUsersSuspenseQueryOptions, getGetOrganisationUsersQueryKey, getGetOrganisationUsersQueryOptions, getGetOrganisationUsersSuspenseQueryOptions, getGetUserAccountQueryKey, getGetUserAccountQueryOptions, getGetUserAccountSuspenseQueryOptions, getOrganisationUnitUsers, getOrganisationUsers, getUserAccount, invalidateGetOrganisationUnitUsers, invalidateGetOrganisationUsers, invalidateGetUserAccount, useAddOrganisationUnitUser, useAddOrganisationUser, useDeleteOrganisationUnitUser, useDeleteOrganisationUser, useGetOrganisationUnitUsers, useGetOrganisationUnitUsersSuspense, useGetOrganisationUsers, useGetOrganisationUsersSuspense, useGetUserAccount, useGetUserAccountSuspense };
|
|
350
386
|
//# sourceMappingURL=user.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"user.js","names":["queryFn: QueryFunction<Awaited<ReturnType<typeof getUserAccount>>>","queryFn: QueryFunction<Awaited<ReturnType<typeof getOrganisationUsers>>>","mutationFn: MutationFunction<\n Awaited<ReturnType<typeof addOrganisationUser>>,\n { orgId: string; userId: string }\n >","mutationFn: MutationFunction<\n Awaited<ReturnType<typeof deleteOrganisationUser>>,\n { orgId: string; userId: string }\n >","queryFn: QueryFunction<Awaited<ReturnType<typeof getOrganisationUnitUsers>>>","mutationFn: MutationFunction<\n Awaited<ReturnType<typeof addOrganisationUnitUser>>,\n { unitId: string; userId: string }\n >","mutationFn: MutationFunction<\n Awaited<ReturnType<typeof deleteOrganisationUnitUser>>,\n { unitId: string; userId: string }\n >"],"sources":["../../../src/api/user/user.ts"],"sourcesContent":["/**\n * Generated by orval v7.17.0 🍺\n * Do not edit manually.\n * Account Server API\n * The Informatics Matters Account Server API.\n\nA service that provides access to the Account Server, which gives *registered* users access to and management of **Organisations**, **Units**, **Products**, **Users**, and **Assets**.\n\n * OpenAPI spec version: 4.4\n */\nimport { useMutation, useQuery, useSuspenseQuery } from \"@tanstack/react-query\";\nimport type {\n MutationFunction,\n QueryFunction,\n QueryKey,\n UseMutationOptions,\n UseMutationResult,\n UseQueryOptions,\n UseQueryResult,\n UseSuspenseQueryOptions,\n UseSuspenseQueryResult,\n} from \"@tanstack/react-query\";\n\nimport type { AsError, UserAccountDetail, UsersGetResponse } from \"../api.schemas\";\n\nimport { customInstance } from \"../../custom-instance\";\nimport type { ErrorType } from \"../../custom-instance\";\nimport { queryMutator } from \"../../options-mutator\";\nimport { mutationMutator } from \"../../options-mutator\";\n\ntype SecondParameter<T extends (...args: never) => unknown> = Parameters<T>[1];\n\n/**\n * Returns a summary of your account\n\n * @summary Get information about your account\n */\nexport const getUserAccount = (\n options?: SecondParameter<typeof customInstance>,\n signal?: AbortSignal,\n) => {\n return customInstance<UserAccountDetail>(\n { url: `/user/account`, method: \"GET\", signal },\n options,\n );\n};\n\nexport const getGetUserAccountQueryKey = () => {\n return [`/user/account`] as const;\n};\n\nexport const useGetUserAccountQueryOptions = <\n TData = Awaited<ReturnType<typeof getUserAccount>>,\n TError = ErrorType<void | AsError>,\n>(options?: {\n query?: UseQueryOptions<Awaited<ReturnType<typeof getUserAccount>>, TError, TData>;\n request?: SecondParameter<typeof customInstance>;\n}) => {\n const { query: queryOptions, request: requestOptions } = options ?? {};\n\n const queryKey = queryOptions?.queryKey ?? getGetUserAccountQueryKey();\n\n const queryFn: QueryFunction<Awaited<ReturnType<typeof getUserAccount>>> = ({ signal }) =>\n getUserAccount(requestOptions, signal);\n\n const customOptions = queryMutator({ ...queryOptions, queryKey, queryFn });\n\n return customOptions as UseQueryOptions<\n Awaited<ReturnType<typeof getUserAccount>>,\n TError,\n TData\n > & { queryKey: QueryKey };\n};\n\nexport type GetUserAccountQueryResult = NonNullable<Awaited<ReturnType<typeof getUserAccount>>>;\nexport type GetUserAccountQueryError = ErrorType<void | AsError>;\n\n/**\n * @summary Get information about your account\n */\n\nexport function useGetUserAccount<\n TData = Awaited<ReturnType<typeof getUserAccount>>,\n TError = ErrorType<void | AsError>,\n>(options?: {\n query?: UseQueryOptions<Awaited<ReturnType<typeof getUserAccount>>, TError, TData>;\n request?: SecondParameter<typeof customInstance>;\n}): UseQueryResult<TData, TError> & { queryKey: QueryKey } {\n const queryOptions = useGetUserAccountQueryOptions(options);\n\n const query = useQuery(queryOptions) as UseQueryResult<TData, TError> & { queryKey: QueryKey };\n\n query.queryKey = queryOptions.queryKey;\n\n return query;\n}\n\nexport const useGetUserAccountSuspenseQueryOptions = <\n TData = Awaited<ReturnType<typeof getUserAccount>>,\n TError = ErrorType<void | AsError>,\n>(options?: {\n query?: UseSuspenseQueryOptions<Awaited<ReturnType<typeof getUserAccount>>, TError, TData>;\n request?: SecondParameter<typeof customInstance>;\n}) => {\n const { query: queryOptions, request: requestOptions } = options ?? {};\n\n const queryKey = queryOptions?.queryKey ?? getGetUserAccountQueryKey();\n\n const queryFn: QueryFunction<Awaited<ReturnType<typeof getUserAccount>>> = ({ signal }) =>\n getUserAccount(requestOptions, signal);\n\n const customOptions = queryMutator({ ...queryOptions, queryKey, queryFn });\n\n return customOptions as UseSuspenseQueryOptions<\n Awaited<ReturnType<typeof getUserAccount>>,\n TError,\n TData\n > & { queryKey: QueryKey };\n};\n\nexport type GetUserAccountSuspenseQueryResult = NonNullable<\n Awaited<ReturnType<typeof getUserAccount>>\n>;\nexport type GetUserAccountSuspenseQueryError = ErrorType<void | AsError>;\n\n/**\n * @summary Get information about your account\n */\n\nexport function useGetUserAccountSuspense<\n TData = Awaited<ReturnType<typeof getUserAccount>>,\n TError = ErrorType<void | AsError>,\n>(options?: {\n query?: UseSuspenseQueryOptions<Awaited<ReturnType<typeof getUserAccount>>, TError, TData>;\n request?: SecondParameter<typeof customInstance>;\n}): UseSuspenseQueryResult<TData, TError> & { queryKey: QueryKey } {\n const queryOptions = useGetUserAccountSuspenseQueryOptions(options);\n\n const query = useSuspenseQuery(queryOptions) as UseSuspenseQueryResult<TData, TError> & {\n queryKey: QueryKey;\n };\n\n query.queryKey = queryOptions.queryKey;\n\n return query;\n}\n\n/**\n * Gets Users in an Organisation.\n\nYou have to be a member of the Organisation or an admin user to use this endpoint\n\n**WARNING**: This endpoint is **DEPRECATED** and will be removed in a future release. Please use the `GET /organisation/{org_id}` endpoint instead.\n\n * @summary Gets users in an Organisation\n */\nexport const getOrganisationUsers = (\n orgId: string,\n options?: SecondParameter<typeof customInstance>,\n signal?: AbortSignal,\n) => {\n return customInstance<UsersGetResponse>(\n { url: `/organisation/${orgId}/user`, method: \"GET\", signal },\n options,\n );\n};\n\nexport const getGetOrganisationUsersQueryKey = (orgId?: string) => {\n return [`/organisation/${orgId}/user`] as const;\n};\n\nexport const useGetOrganisationUsersQueryOptions = <\n TData = Awaited<ReturnType<typeof getOrganisationUsers>>,\n TError = ErrorType<AsError | void>,\n>(\n orgId: string,\n options?: {\n query?: UseQueryOptions<Awaited<ReturnType<typeof getOrganisationUsers>>, TError, TData>;\n request?: SecondParameter<typeof customInstance>;\n },\n) => {\n const { query: queryOptions, request: requestOptions } = options ?? {};\n\n const queryKey = queryOptions?.queryKey ?? getGetOrganisationUsersQueryKey(orgId);\n\n const queryFn: QueryFunction<Awaited<ReturnType<typeof getOrganisationUsers>>> = ({ signal }) =>\n getOrganisationUsers(orgId, requestOptions, signal);\n\n const customOptions = queryMutator({ ...queryOptions, queryKey, queryFn });\n\n return customOptions as UseQueryOptions<\n Awaited<ReturnType<typeof getOrganisationUsers>>,\n TError,\n TData\n > & { queryKey: QueryKey };\n};\n\nexport type GetOrganisationUsersQueryResult = NonNullable<\n Awaited<ReturnType<typeof getOrganisationUsers>>\n>;\nexport type GetOrganisationUsersQueryError = ErrorType<AsError | void>;\n\n/**\n * @summary Gets users in an Organisation\n */\n\nexport function useGetOrganisationUsers<\n TData = Awaited<ReturnType<typeof getOrganisationUsers>>,\n TError = ErrorType<AsError | void>,\n>(\n orgId: string,\n options?: {\n query?: UseQueryOptions<Awaited<ReturnType<typeof getOrganisationUsers>>, TError, TData>;\n request?: SecondParameter<typeof customInstance>;\n },\n): UseQueryResult<TData, TError> & { queryKey: QueryKey } {\n const queryOptions = useGetOrganisationUsersQueryOptions(orgId, options);\n\n const query = useQuery(queryOptions) as UseQueryResult<TData, TError> & { queryKey: QueryKey };\n\n query.queryKey = queryOptions.queryKey;\n\n return query;\n}\n\nexport const useGetOrganisationUsersSuspenseQueryOptions = <\n TData = Awaited<ReturnType<typeof getOrganisationUsers>>,\n TError = ErrorType<AsError | void>,\n>(\n orgId: string,\n options?: {\n query?: UseSuspenseQueryOptions<\n Awaited<ReturnType<typeof getOrganisationUsers>>,\n TError,\n TData\n >;\n request?: SecondParameter<typeof customInstance>;\n },\n) => {\n const { query: queryOptions, request: requestOptions } = options ?? {};\n\n const queryKey = queryOptions?.queryKey ?? getGetOrganisationUsersQueryKey(orgId);\n\n const queryFn: QueryFunction<Awaited<ReturnType<typeof getOrganisationUsers>>> = ({ signal }) =>\n getOrganisationUsers(orgId, requestOptions, signal);\n\n const customOptions = queryMutator({ ...queryOptions, queryKey, queryFn });\n\n return customOptions as UseSuspenseQueryOptions<\n Awaited<ReturnType<typeof getOrganisationUsers>>,\n TError,\n TData\n > & { queryKey: QueryKey };\n};\n\nexport type GetOrganisationUsersSuspenseQueryResult = NonNullable<\n Awaited<ReturnType<typeof getOrganisationUsers>>\n>;\nexport type GetOrganisationUsersSuspenseQueryError = ErrorType<AsError | void>;\n\n/**\n * @summary Gets users in an Organisation\n */\n\nexport function useGetOrganisationUsersSuspense<\n TData = Awaited<ReturnType<typeof getOrganisationUsers>>,\n TError = ErrorType<AsError | void>,\n>(\n orgId: string,\n options?: {\n query?: UseSuspenseQueryOptions<\n Awaited<ReturnType<typeof getOrganisationUsers>>,\n TError,\n TData\n >;\n request?: SecondParameter<typeof customInstance>;\n },\n): UseSuspenseQueryResult<TData, TError> & { queryKey: QueryKey } {\n const queryOptions = useGetOrganisationUsersSuspenseQueryOptions(orgId, options);\n\n const query = useSuspenseQuery(queryOptions) as UseSuspenseQueryResult<TData, TError> & {\n queryKey: QueryKey;\n };\n\n query.queryKey = queryOptions.queryKey;\n\n return query;\n}\n\n/**\n * Adds a User to an **Organisation**.\n\nYou have to be in the Organisation or an admin user to use this endpoint\n\n * @summary Adds a User to an Organisation\n */\nexport const addOrganisationUser = (\n orgId: string,\n userId: string,\n options?: SecondParameter<typeof customInstance>,\n) => {\n return customInstance<void>(\n { url: `/organisation/${orgId}/user/${userId}`, method: \"PUT\" },\n options,\n );\n};\n\nexport const useAddOrganisationUserMutationOptions = <\n TError = ErrorType<AsError | void>,\n TContext = unknown,\n>(options?: {\n mutation?: UseMutationOptions<\n Awaited<ReturnType<typeof addOrganisationUser>>,\n TError,\n { orgId: string; userId: string },\n TContext\n >;\n request?: SecondParameter<typeof customInstance>;\n}): UseMutationOptions<\n Awaited<ReturnType<typeof addOrganisationUser>>,\n TError,\n { orgId: string; userId: string },\n TContext\n> => {\n const mutationKey = [\"addOrganisationUser\"];\n const { mutation: mutationOptions, request: requestOptions } = options\n ? options.mutation && \"mutationKey\" in options.mutation && options.mutation.mutationKey\n ? options\n : { ...options, mutation: { ...options.mutation, mutationKey } }\n : { mutation: { mutationKey }, request: undefined };\n\n const mutationFn: MutationFunction<\n Awaited<ReturnType<typeof addOrganisationUser>>,\n { orgId: string; userId: string }\n > = (props) => {\n const { orgId, userId } = props ?? {};\n\n return addOrganisationUser(orgId, userId, requestOptions);\n };\n\n const customOptions = mutationMutator({ ...mutationOptions, mutationFn });\n\n return customOptions;\n};\n\nexport type AddOrganisationUserMutationResult = NonNullable<\n Awaited<ReturnType<typeof addOrganisationUser>>\n>;\n\nexport type AddOrganisationUserMutationError = ErrorType<AsError | void>;\n\n/**\n * @summary Adds a User to an Organisation\n */\nexport const useAddOrganisationUser = <\n TError = ErrorType<AsError | void>,\n TContext = unknown,\n>(options?: {\n mutation?: UseMutationOptions<\n Awaited<ReturnType<typeof addOrganisationUser>>,\n TError,\n { orgId: string; userId: string },\n TContext\n >;\n request?: SecondParameter<typeof customInstance>;\n}): UseMutationResult<\n Awaited<ReturnType<typeof addOrganisationUser>>,\n TError,\n { orgId: string; userId: string },\n TContext\n> => {\n const mutationOptions = useAddOrganisationUserMutationOptions(options);\n\n return useMutation(mutationOptions);\n};\n/**\n * Removes a User from an **Organisation**.\n\nYou have to be in the Organisation or an admin user to use this endpoint\n\n * @summary Deletes a User from an Organisation\n */\nexport const deleteOrganisationUser = (\n orgId: string,\n userId: string,\n options?: SecondParameter<typeof customInstance>,\n) => {\n return customInstance<void>(\n { url: `/organisation/${orgId}/user/${userId}`, method: \"DELETE\" },\n options,\n );\n};\n\nexport const useDeleteOrganisationUserMutationOptions = <\n TError = ErrorType<AsError | void>,\n TContext = unknown,\n>(options?: {\n mutation?: UseMutationOptions<\n Awaited<ReturnType<typeof deleteOrganisationUser>>,\n TError,\n { orgId: string; userId: string },\n TContext\n >;\n request?: SecondParameter<typeof customInstance>;\n}): UseMutationOptions<\n Awaited<ReturnType<typeof deleteOrganisationUser>>,\n TError,\n { orgId: string; userId: string },\n TContext\n> => {\n const mutationKey = [\"deleteOrganisationUser\"];\n const { mutation: mutationOptions, request: requestOptions } = options\n ? options.mutation && \"mutationKey\" in options.mutation && options.mutation.mutationKey\n ? options\n : { ...options, mutation: { ...options.mutation, mutationKey } }\n : { mutation: { mutationKey }, request: undefined };\n\n const mutationFn: MutationFunction<\n Awaited<ReturnType<typeof deleteOrganisationUser>>,\n { orgId: string; userId: string }\n > = (props) => {\n const { orgId, userId } = props ?? {};\n\n return deleteOrganisationUser(orgId, userId, requestOptions);\n };\n\n const customOptions = mutationMutator({ ...mutationOptions, mutationFn });\n\n return customOptions;\n};\n\nexport type DeleteOrganisationUserMutationResult = NonNullable<\n Awaited<ReturnType<typeof deleteOrganisationUser>>\n>;\n\nexport type DeleteOrganisationUserMutationError = ErrorType<AsError | void>;\n\n/**\n * @summary Deletes a User from an Organisation\n */\nexport const useDeleteOrganisationUser = <\n TError = ErrorType<AsError | void>,\n TContext = unknown,\n>(options?: {\n mutation?: UseMutationOptions<\n Awaited<ReturnType<typeof deleteOrganisationUser>>,\n TError,\n { orgId: string; userId: string },\n TContext\n >;\n request?: SecondParameter<typeof customInstance>;\n}): UseMutationResult<\n Awaited<ReturnType<typeof deleteOrganisationUser>>,\n TError,\n { orgId: string; userId: string },\n TContext\n> => {\n const mutationOptions = useDeleteOrganisationUserMutationOptions(options);\n\n return useMutation(mutationOptions);\n};\n/**\n * Gets users in an Organisational Unit.\n\nYou have to be in the Organisation or Unit or an Admin user to use this endpoint\n\n**WARNING**: This endpoint is **DEPRECATED** and will be removed in a future release. Please use the `GET /unit/{unit_id}` endpoint instead.\n\n * @summary Gets users in an Organisational Unit\n */\nexport const getOrganisationUnitUsers = (\n unitId: string,\n options?: SecondParameter<typeof customInstance>,\n signal?: AbortSignal,\n) => {\n return customInstance<UsersGetResponse>(\n { url: `/unit/${unitId}/user`, method: \"GET\", signal },\n options,\n );\n};\n\nexport const getGetOrganisationUnitUsersQueryKey = (unitId?: string) => {\n return [`/unit/${unitId}/user`] as const;\n};\n\nexport const useGetOrganisationUnitUsersQueryOptions = <\n TData = Awaited<ReturnType<typeof getOrganisationUnitUsers>>,\n TError = ErrorType<AsError | void>,\n>(\n unitId: string,\n options?: {\n query?: UseQueryOptions<Awaited<ReturnType<typeof getOrganisationUnitUsers>>, TError, TData>;\n request?: SecondParameter<typeof customInstance>;\n },\n) => {\n const { query: queryOptions, request: requestOptions } = options ?? {};\n\n const queryKey = queryOptions?.queryKey ?? getGetOrganisationUnitUsersQueryKey(unitId);\n\n const queryFn: QueryFunction<Awaited<ReturnType<typeof getOrganisationUnitUsers>>> = ({\n signal,\n }) => getOrganisationUnitUsers(unitId, requestOptions, signal);\n\n const customOptions = queryMutator({ ...queryOptions, queryKey, queryFn });\n\n return customOptions as UseQueryOptions<\n Awaited<ReturnType<typeof getOrganisationUnitUsers>>,\n TError,\n TData\n > & { queryKey: QueryKey };\n};\n\nexport type GetOrganisationUnitUsersQueryResult = NonNullable<\n Awaited<ReturnType<typeof getOrganisationUnitUsers>>\n>;\nexport type GetOrganisationUnitUsersQueryError = ErrorType<AsError | void>;\n\n/**\n * @summary Gets users in an Organisational Unit\n */\n\nexport function useGetOrganisationUnitUsers<\n TData = Awaited<ReturnType<typeof getOrganisationUnitUsers>>,\n TError = ErrorType<AsError | void>,\n>(\n unitId: string,\n options?: {\n query?: UseQueryOptions<Awaited<ReturnType<typeof getOrganisationUnitUsers>>, TError, TData>;\n request?: SecondParameter<typeof customInstance>;\n },\n): UseQueryResult<TData, TError> & { queryKey: QueryKey } {\n const queryOptions = useGetOrganisationUnitUsersQueryOptions(unitId, options);\n\n const query = useQuery(queryOptions) as UseQueryResult<TData, TError> & { queryKey: QueryKey };\n\n query.queryKey = queryOptions.queryKey;\n\n return query;\n}\n\nexport const useGetOrganisationUnitUsersSuspenseQueryOptions = <\n TData = Awaited<ReturnType<typeof getOrganisationUnitUsers>>,\n TError = ErrorType<AsError | void>,\n>(\n unitId: string,\n options?: {\n query?: UseSuspenseQueryOptions<\n Awaited<ReturnType<typeof getOrganisationUnitUsers>>,\n TError,\n TData\n >;\n request?: SecondParameter<typeof customInstance>;\n },\n) => {\n const { query: queryOptions, request: requestOptions } = options ?? {};\n\n const queryKey = queryOptions?.queryKey ?? getGetOrganisationUnitUsersQueryKey(unitId);\n\n const queryFn: QueryFunction<Awaited<ReturnType<typeof getOrganisationUnitUsers>>> = ({\n signal,\n }) => getOrganisationUnitUsers(unitId, requestOptions, signal);\n\n const customOptions = queryMutator({ ...queryOptions, queryKey, queryFn });\n\n return customOptions as UseSuspenseQueryOptions<\n Awaited<ReturnType<typeof getOrganisationUnitUsers>>,\n TError,\n TData\n > & { queryKey: QueryKey };\n};\n\nexport type GetOrganisationUnitUsersSuspenseQueryResult = NonNullable<\n Awaited<ReturnType<typeof getOrganisationUnitUsers>>\n>;\nexport type GetOrganisationUnitUsersSuspenseQueryError = ErrorType<AsError | void>;\n\n/**\n * @summary Gets users in an Organisational Unit\n */\n\nexport function useGetOrganisationUnitUsersSuspense<\n TData = Awaited<ReturnType<typeof getOrganisationUnitUsers>>,\n TError = ErrorType<AsError | void>,\n>(\n unitId: string,\n options?: {\n query?: UseSuspenseQueryOptions<\n Awaited<ReturnType<typeof getOrganisationUnitUsers>>,\n TError,\n TData\n >;\n request?: SecondParameter<typeof customInstance>;\n },\n): UseSuspenseQueryResult<TData, TError> & { queryKey: QueryKey } {\n const queryOptions = useGetOrganisationUnitUsersSuspenseQueryOptions(unitId, options);\n\n const query = useSuspenseQuery(queryOptions) as UseSuspenseQueryResult<TData, TError> & {\n queryKey: QueryKey;\n };\n\n query.queryKey = queryOptions.queryKey;\n\n return query;\n}\n\n/**\n * Adds a user to an Organisational Unit.\n\nUsers cannot be added to **Personal Units** (Units that are part of the ***Default** Organisation).\n\nYou have to be in the Organisation or Unit or an Admin user to use this endpoint\n\n * @summary Adds a user to an Organisational Unit\n */\nexport const addOrganisationUnitUser = (\n unitId: string,\n userId: string,\n options?: SecondParameter<typeof customInstance>,\n) => {\n return customInstance<void>({ url: `/unit/${unitId}/user/${userId}`, method: \"PUT\" }, options);\n};\n\nexport const useAddOrganisationUnitUserMutationOptions = <\n TError = ErrorType<AsError | void>,\n TContext = unknown,\n>(options?: {\n mutation?: UseMutationOptions<\n Awaited<ReturnType<typeof addOrganisationUnitUser>>,\n TError,\n { unitId: string; userId: string },\n TContext\n >;\n request?: SecondParameter<typeof customInstance>;\n}): UseMutationOptions<\n Awaited<ReturnType<typeof addOrganisationUnitUser>>,\n TError,\n { unitId: string; userId: string },\n TContext\n> => {\n const mutationKey = [\"addOrganisationUnitUser\"];\n const { mutation: mutationOptions, request: requestOptions } = options\n ? options.mutation && \"mutationKey\" in options.mutation && options.mutation.mutationKey\n ? options\n : { ...options, mutation: { ...options.mutation, mutationKey } }\n : { mutation: { mutationKey }, request: undefined };\n\n const mutationFn: MutationFunction<\n Awaited<ReturnType<typeof addOrganisationUnitUser>>,\n { unitId: string; userId: string }\n > = (props) => {\n const { unitId, userId } = props ?? {};\n\n return addOrganisationUnitUser(unitId, userId, requestOptions);\n };\n\n const customOptions = mutationMutator({ ...mutationOptions, mutationFn });\n\n return customOptions;\n};\n\nexport type AddOrganisationUnitUserMutationResult = NonNullable<\n Awaited<ReturnType<typeof addOrganisationUnitUser>>\n>;\n\nexport type AddOrganisationUnitUserMutationError = ErrorType<AsError | void>;\n\n/**\n * @summary Adds a user to an Organisational Unit\n */\nexport const useAddOrganisationUnitUser = <\n TError = ErrorType<AsError | void>,\n TContext = unknown,\n>(options?: {\n mutation?: UseMutationOptions<\n Awaited<ReturnType<typeof addOrganisationUnitUser>>,\n TError,\n { unitId: string; userId: string },\n TContext\n >;\n request?: SecondParameter<typeof customInstance>;\n}): UseMutationResult<\n Awaited<ReturnType<typeof addOrganisationUnitUser>>,\n TError,\n { unitId: string; userId: string },\n TContext\n> => {\n const mutationOptions = useAddOrganisationUnitUserMutationOptions(options);\n\n return useMutation(mutationOptions);\n};\n/**\n * Removes a User from an Organisational Unit.\n\nUsers cannot be removed from **Personal Units** (Units that are part of the ***Default** Organisation).\n\nYou have to be in the Organisation or Unit or an Admin user to use this endpoint\n\n * @summary Deletes a User from an Organisational Unit\n */\nexport const deleteOrganisationUnitUser = (\n unitId: string,\n userId: string,\n options?: SecondParameter<typeof customInstance>,\n) => {\n return customInstance<void>({ url: `/unit/${unitId}/user/${userId}`, method: \"DELETE\" }, options);\n};\n\nexport const useDeleteOrganisationUnitUserMutationOptions = <\n TError = ErrorType<AsError | void>,\n TContext = unknown,\n>(options?: {\n mutation?: UseMutationOptions<\n Awaited<ReturnType<typeof deleteOrganisationUnitUser>>,\n TError,\n { unitId: string; userId: string },\n TContext\n >;\n request?: SecondParameter<typeof customInstance>;\n}): UseMutationOptions<\n Awaited<ReturnType<typeof deleteOrganisationUnitUser>>,\n TError,\n { unitId: string; userId: string },\n TContext\n> => {\n const mutationKey = [\"deleteOrganisationUnitUser\"];\n const { mutation: mutationOptions, request: requestOptions } = options\n ? options.mutation && \"mutationKey\" in options.mutation && options.mutation.mutationKey\n ? options\n : { ...options, mutation: { ...options.mutation, mutationKey } }\n : { mutation: { mutationKey }, request: undefined };\n\n const mutationFn: MutationFunction<\n Awaited<ReturnType<typeof deleteOrganisationUnitUser>>,\n { unitId: string; userId: string }\n > = (props) => {\n const { unitId, userId } = props ?? {};\n\n return deleteOrganisationUnitUser(unitId, userId, requestOptions);\n };\n\n const customOptions = mutationMutator({ ...mutationOptions, mutationFn });\n\n return customOptions;\n};\n\nexport type DeleteOrganisationUnitUserMutationResult = NonNullable<\n Awaited<ReturnType<typeof deleteOrganisationUnitUser>>\n>;\n\nexport type DeleteOrganisationUnitUserMutationError = ErrorType<AsError | void>;\n\n/**\n * @summary Deletes a User from an Organisational Unit\n */\nexport const useDeleteOrganisationUnitUser = <\n TError = ErrorType<AsError | void>,\n TContext = unknown,\n>(options?: {\n mutation?: UseMutationOptions<\n Awaited<ReturnType<typeof deleteOrganisationUnitUser>>,\n TError,\n { unitId: string; userId: string },\n TContext\n >;\n request?: SecondParameter<typeof customInstance>;\n}): UseMutationResult<\n Awaited<ReturnType<typeof deleteOrganisationUnitUser>>,\n TError,\n { unitId: string; userId: string },\n TContext\n> => {\n const mutationOptions = useDeleteOrganisationUnitUserMutationOptions(options);\n\n return useMutation(mutationOptions);\n};\n"],"mappings":"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"}
|
|
1
|
+
{"version":3,"file":"user.js","names":["queryFn: QueryFunction<Awaited<ReturnType<typeof getUserAccount>>>","queryFn: QueryFunction<Awaited<ReturnType<typeof getOrganisationUsers>>>","mutationFn: MutationFunction<\n Awaited<ReturnType<typeof addOrganisationUser>>,\n { orgId: string; userId: string }\n >","mutationFn: MutationFunction<\n Awaited<ReturnType<typeof deleteOrganisationUser>>,\n { orgId: string; userId: string }\n >","queryFn: QueryFunction<Awaited<ReturnType<typeof getOrganisationUnitUsers>>>","mutationFn: MutationFunction<\n Awaited<ReturnType<typeof addOrganisationUnitUser>>,\n { unitId: string; userId: string }\n >","mutationFn: MutationFunction<\n Awaited<ReturnType<typeof deleteOrganisationUnitUser>>,\n { unitId: string; userId: string }\n >"],"sources":["../../../src/api/user/user.ts"],"sourcesContent":["/**\n * Generated by orval v7.17.0 🍺\n * Do not edit manually.\n * Account Server API\n * The Informatics Matters Account Server API.\n\nA service that provides access to the Account Server, which gives *registered* users access to and management of **Organisations**, **Units**, **Products**, **Users**, and **Assets**.\n\n * OpenAPI spec version: 4.4\n */\nimport { useMutation, useQuery, useSuspenseQuery } from \"@tanstack/react-query\";\nimport type {\n InvalidateOptions,\n MutationFunction,\n QueryClient,\n QueryFunction,\n QueryKey,\n UseMutationOptions,\n UseMutationResult,\n UseQueryOptions,\n UseQueryResult,\n UseSuspenseQueryOptions,\n UseSuspenseQueryResult,\n} from \"@tanstack/react-query\";\n\nimport type { AsError, UserAccountDetail, UsersGetResponse } from \".././api-schemas\";\n\nimport { customInstance } from \"../../custom-axios\";\nimport type { ErrorType } from \"../../custom-axios\";\n\ntype SecondParameter<T extends (...args: never) => unknown> = Parameters<T>[1];\n\n/**\n * Returns a summary of your account\n\n * @summary Get information about your account\n */\nexport const getUserAccount = (\n options?: SecondParameter<typeof customInstance>,\n signal?: AbortSignal,\n) => {\n return customInstance<UserAccountDetail>(\n { url: `/user/account`, method: \"GET\", signal },\n options,\n );\n};\n\nexport const getGetUserAccountQueryKey = () => {\n return [\"account-server\", \"user\", \"account\"] as const;\n};\n\nexport const getGetUserAccountQueryOptions = <\n TData = Awaited<ReturnType<typeof getUserAccount>>,\n TError = ErrorType<void | AsError>,\n>(options?: {\n query?: UseQueryOptions<Awaited<ReturnType<typeof getUserAccount>>, TError, TData>;\n request?: SecondParameter<typeof customInstance>;\n}) => {\n const { query: queryOptions, request: requestOptions } = options ?? {};\n\n const queryKey = queryOptions?.queryKey ?? getGetUserAccountQueryKey();\n\n const queryFn: QueryFunction<Awaited<ReturnType<typeof getUserAccount>>> = ({ signal }) =>\n getUserAccount(requestOptions, signal);\n\n return { queryKey, queryFn, ...queryOptions } as UseQueryOptions<\n Awaited<ReturnType<typeof getUserAccount>>,\n TError,\n TData\n > & { queryKey: QueryKey };\n};\n\nexport type GetUserAccountQueryResult = NonNullable<Awaited<ReturnType<typeof getUserAccount>>>;\nexport type GetUserAccountQueryError = ErrorType<void | AsError>;\n\n/**\n * @summary Get information about your account\n */\n\nexport function useGetUserAccount<\n TData = Awaited<ReturnType<typeof getUserAccount>>,\n TError = ErrorType<void | AsError>,\n>(options?: {\n query?: UseQueryOptions<Awaited<ReturnType<typeof getUserAccount>>, TError, TData>;\n request?: SecondParameter<typeof customInstance>;\n}): UseQueryResult<TData, TError> & { queryKey: QueryKey } {\n const queryOptions = getGetUserAccountQueryOptions(options);\n\n const query = useQuery(queryOptions) as UseQueryResult<TData, TError> & { queryKey: QueryKey };\n\n query.queryKey = queryOptions.queryKey;\n\n return query;\n}\n\n/**\n * @summary Get information about your account\n */\nexport const invalidateGetUserAccount = async (\n queryClient: QueryClient,\n options?: InvalidateOptions,\n): Promise<QueryClient> => {\n await queryClient.invalidateQueries({ queryKey: getGetUserAccountQueryKey() }, options);\n\n return queryClient;\n};\n\nexport const getGetUserAccountSuspenseQueryOptions = <\n TData = Awaited<ReturnType<typeof getUserAccount>>,\n TError = ErrorType<void | AsError>,\n>(options?: {\n query?: UseSuspenseQueryOptions<Awaited<ReturnType<typeof getUserAccount>>, TError, TData>;\n request?: SecondParameter<typeof customInstance>;\n}) => {\n const { query: queryOptions, request: requestOptions } = options ?? {};\n\n const queryKey = queryOptions?.queryKey ?? getGetUserAccountQueryKey();\n\n const queryFn: QueryFunction<Awaited<ReturnType<typeof getUserAccount>>> = ({ signal }) =>\n getUserAccount(requestOptions, signal);\n\n return { queryKey, queryFn, ...queryOptions } as UseSuspenseQueryOptions<\n Awaited<ReturnType<typeof getUserAccount>>,\n TError,\n TData\n > & { queryKey: QueryKey };\n};\n\nexport type GetUserAccountSuspenseQueryResult = NonNullable<\n Awaited<ReturnType<typeof getUserAccount>>\n>;\nexport type GetUserAccountSuspenseQueryError = ErrorType<void | AsError>;\n\n/**\n * @summary Get information about your account\n */\n\nexport function useGetUserAccountSuspense<\n TData = Awaited<ReturnType<typeof getUserAccount>>,\n TError = ErrorType<void | AsError>,\n>(options?: {\n query?: UseSuspenseQueryOptions<Awaited<ReturnType<typeof getUserAccount>>, TError, TData>;\n request?: SecondParameter<typeof customInstance>;\n}): UseSuspenseQueryResult<TData, TError> & { queryKey: QueryKey } {\n const queryOptions = getGetUserAccountSuspenseQueryOptions(options);\n\n const query = useSuspenseQuery(queryOptions) as UseSuspenseQueryResult<TData, TError> & {\n queryKey: QueryKey;\n };\n\n query.queryKey = queryOptions.queryKey;\n\n return query;\n}\n\n/**\n * Gets Users in an Organisation.\n\nYou have to be a member of the Organisation or an admin user to use this endpoint\n\n**WARNING**: This endpoint is **DEPRECATED** and will be removed in a future release. Please use the `GET /organisation/{org_id}` endpoint instead.\n\n * @summary Gets users in an Organisation\n */\nexport const getOrganisationUsers = (\n orgId: string,\n options?: SecondParameter<typeof customInstance>,\n signal?: AbortSignal,\n) => {\n return customInstance<UsersGetResponse>(\n { url: `/organisation/${orgId}/user`, method: \"GET\", signal },\n options,\n );\n};\n\nexport const getGetOrganisationUsersQueryKey = (orgId?: string) => {\n return [\"account-server\", \"organisation\", orgId, \"user\"] as const;\n};\n\nexport const getGetOrganisationUsersQueryOptions = <\n TData = Awaited<ReturnType<typeof getOrganisationUsers>>,\n TError = ErrorType<AsError | void>,\n>(\n orgId: string,\n options?: {\n query?: UseQueryOptions<Awaited<ReturnType<typeof getOrganisationUsers>>, TError, TData>;\n request?: SecondParameter<typeof customInstance>;\n },\n) => {\n const { query: queryOptions, request: requestOptions } = options ?? {};\n\n const queryKey = queryOptions?.queryKey ?? getGetOrganisationUsersQueryKey(orgId);\n\n const queryFn: QueryFunction<Awaited<ReturnType<typeof getOrganisationUsers>>> = ({ signal }) =>\n getOrganisationUsers(orgId, requestOptions, signal);\n\n return { queryKey, queryFn, enabled: !!orgId, ...queryOptions } as UseQueryOptions<\n Awaited<ReturnType<typeof getOrganisationUsers>>,\n TError,\n TData\n > & { queryKey: QueryKey };\n};\n\nexport type GetOrganisationUsersQueryResult = NonNullable<\n Awaited<ReturnType<typeof getOrganisationUsers>>\n>;\nexport type GetOrganisationUsersQueryError = ErrorType<AsError | void>;\n\n/**\n * @summary Gets users in an Organisation\n */\n\nexport function useGetOrganisationUsers<\n TData = Awaited<ReturnType<typeof getOrganisationUsers>>,\n TError = ErrorType<AsError | void>,\n>(\n orgId: string,\n options?: {\n query?: UseQueryOptions<Awaited<ReturnType<typeof getOrganisationUsers>>, TError, TData>;\n request?: SecondParameter<typeof customInstance>;\n },\n): UseQueryResult<TData, TError> & { queryKey: QueryKey } {\n const queryOptions = getGetOrganisationUsersQueryOptions(orgId, options);\n\n const query = useQuery(queryOptions) as UseQueryResult<TData, TError> & { queryKey: QueryKey };\n\n query.queryKey = queryOptions.queryKey;\n\n return query;\n}\n\n/**\n * @summary Gets users in an Organisation\n */\nexport const invalidateGetOrganisationUsers = async (\n queryClient: QueryClient,\n orgId: string,\n options?: InvalidateOptions,\n): Promise<QueryClient> => {\n await queryClient.invalidateQueries(\n { queryKey: getGetOrganisationUsersQueryKey(orgId) },\n options,\n );\n\n return queryClient;\n};\n\nexport const getGetOrganisationUsersSuspenseQueryOptions = <\n TData = Awaited<ReturnType<typeof getOrganisationUsers>>,\n TError = ErrorType<AsError | void>,\n>(\n orgId: string,\n options?: {\n query?: UseSuspenseQueryOptions<\n Awaited<ReturnType<typeof getOrganisationUsers>>,\n TError,\n TData\n >;\n request?: SecondParameter<typeof customInstance>;\n },\n) => {\n const { query: queryOptions, request: requestOptions } = options ?? {};\n\n const queryKey = queryOptions?.queryKey ?? getGetOrganisationUsersQueryKey(orgId);\n\n const queryFn: QueryFunction<Awaited<ReturnType<typeof getOrganisationUsers>>> = ({ signal }) =>\n getOrganisationUsers(orgId, requestOptions, signal);\n\n return { queryKey, queryFn, ...queryOptions } as UseSuspenseQueryOptions<\n Awaited<ReturnType<typeof getOrganisationUsers>>,\n TError,\n TData\n > & { queryKey: QueryKey };\n};\n\nexport type GetOrganisationUsersSuspenseQueryResult = NonNullable<\n Awaited<ReturnType<typeof getOrganisationUsers>>\n>;\nexport type GetOrganisationUsersSuspenseQueryError = ErrorType<AsError | void>;\n\n/**\n * @summary Gets users in an Organisation\n */\n\nexport function useGetOrganisationUsersSuspense<\n TData = Awaited<ReturnType<typeof getOrganisationUsers>>,\n TError = ErrorType<AsError | void>,\n>(\n orgId: string,\n options?: {\n query?: UseSuspenseQueryOptions<\n Awaited<ReturnType<typeof getOrganisationUsers>>,\n TError,\n TData\n >;\n request?: SecondParameter<typeof customInstance>;\n },\n): UseSuspenseQueryResult<TData, TError> & { queryKey: QueryKey } {\n const queryOptions = getGetOrganisationUsersSuspenseQueryOptions(orgId, options);\n\n const query = useSuspenseQuery(queryOptions) as UseSuspenseQueryResult<TData, TError> & {\n queryKey: QueryKey;\n };\n\n query.queryKey = queryOptions.queryKey;\n\n return query;\n}\n\n/**\n * Adds a User to an **Organisation**.\n\nYou have to be in the Organisation or an admin user to use this endpoint\n\n * @summary Adds a User to an Organisation\n */\nexport const addOrganisationUser = (\n orgId: string,\n userId: string,\n options?: SecondParameter<typeof customInstance>,\n) => {\n return customInstance<void>(\n { url: `/organisation/${orgId}/user/${userId}`, method: \"PUT\" },\n options,\n );\n};\n\nexport const getAddOrganisationUserMutationOptions = <\n TError = ErrorType<AsError | void>,\n TContext = unknown,\n>(options?: {\n mutation?: UseMutationOptions<\n Awaited<ReturnType<typeof addOrganisationUser>>,\n TError,\n { orgId: string; userId: string },\n TContext\n >;\n request?: SecondParameter<typeof customInstance>;\n}): UseMutationOptions<\n Awaited<ReturnType<typeof addOrganisationUser>>,\n TError,\n { orgId: string; userId: string },\n TContext\n> => {\n const mutationKey = [\"addOrganisationUser\"];\n const { mutation: mutationOptions, request: requestOptions } = options\n ? options.mutation && \"mutationKey\" in options.mutation && options.mutation.mutationKey\n ? options\n : { ...options, mutation: { ...options.mutation, mutationKey } }\n : { mutation: { mutationKey }, request: undefined };\n\n const mutationFn: MutationFunction<\n Awaited<ReturnType<typeof addOrganisationUser>>,\n { orgId: string; userId: string }\n > = (props) => {\n const { orgId, userId } = props ?? {};\n\n return addOrganisationUser(orgId, userId, requestOptions);\n };\n\n return { mutationFn, ...mutationOptions };\n};\n\nexport type AddOrganisationUserMutationResult = NonNullable<\n Awaited<ReturnType<typeof addOrganisationUser>>\n>;\n\nexport type AddOrganisationUserMutationError = ErrorType<AsError | void>;\n\n/**\n * @summary Adds a User to an Organisation\n */\nexport const useAddOrganisationUser = <\n TError = ErrorType<AsError | void>,\n TContext = unknown,\n>(options?: {\n mutation?: UseMutationOptions<\n Awaited<ReturnType<typeof addOrganisationUser>>,\n TError,\n { orgId: string; userId: string },\n TContext\n >;\n request?: SecondParameter<typeof customInstance>;\n}): UseMutationResult<\n Awaited<ReturnType<typeof addOrganisationUser>>,\n TError,\n { orgId: string; userId: string },\n TContext\n> => {\n const mutationOptions = getAddOrganisationUserMutationOptions(options);\n\n return useMutation(mutationOptions);\n};\n/**\n * Removes a User from an **Organisation**.\n\nYou have to be in the Organisation or an admin user to use this endpoint\n\n * @summary Deletes a User from an Organisation\n */\nexport const deleteOrganisationUser = (\n orgId: string,\n userId: string,\n options?: SecondParameter<typeof customInstance>,\n) => {\n return customInstance<void>(\n { url: `/organisation/${orgId}/user/${userId}`, method: \"DELETE\" },\n options,\n );\n};\n\nexport const getDeleteOrganisationUserMutationOptions = <\n TError = ErrorType<AsError | void>,\n TContext = unknown,\n>(options?: {\n mutation?: UseMutationOptions<\n Awaited<ReturnType<typeof deleteOrganisationUser>>,\n TError,\n { orgId: string; userId: string },\n TContext\n >;\n request?: SecondParameter<typeof customInstance>;\n}): UseMutationOptions<\n Awaited<ReturnType<typeof deleteOrganisationUser>>,\n TError,\n { orgId: string; userId: string },\n TContext\n> => {\n const mutationKey = [\"deleteOrganisationUser\"];\n const { mutation: mutationOptions, request: requestOptions } = options\n ? options.mutation && \"mutationKey\" in options.mutation && options.mutation.mutationKey\n ? options\n : { ...options, mutation: { ...options.mutation, mutationKey } }\n : { mutation: { mutationKey }, request: undefined };\n\n const mutationFn: MutationFunction<\n Awaited<ReturnType<typeof deleteOrganisationUser>>,\n { orgId: string; userId: string }\n > = (props) => {\n const { orgId, userId } = props ?? {};\n\n return deleteOrganisationUser(orgId, userId, requestOptions);\n };\n\n return { mutationFn, ...mutationOptions };\n};\n\nexport type DeleteOrganisationUserMutationResult = NonNullable<\n Awaited<ReturnType<typeof deleteOrganisationUser>>\n>;\n\nexport type DeleteOrganisationUserMutationError = ErrorType<AsError | void>;\n\n/**\n * @summary Deletes a User from an Organisation\n */\nexport const useDeleteOrganisationUser = <\n TError = ErrorType<AsError | void>,\n TContext = unknown,\n>(options?: {\n mutation?: UseMutationOptions<\n Awaited<ReturnType<typeof deleteOrganisationUser>>,\n TError,\n { orgId: string; userId: string },\n TContext\n >;\n request?: SecondParameter<typeof customInstance>;\n}): UseMutationResult<\n Awaited<ReturnType<typeof deleteOrganisationUser>>,\n TError,\n { orgId: string; userId: string },\n TContext\n> => {\n const mutationOptions = getDeleteOrganisationUserMutationOptions(options);\n\n return useMutation(mutationOptions);\n};\n/**\n * Gets users in an Organisational Unit.\n\nYou have to be in the Organisation or Unit or an Admin user to use this endpoint\n\n**WARNING**: This endpoint is **DEPRECATED** and will be removed in a future release. Please use the `GET /unit/{unit_id}` endpoint instead.\n\n * @summary Gets users in an Organisational Unit\n */\nexport const getOrganisationUnitUsers = (\n unitId: string,\n options?: SecondParameter<typeof customInstance>,\n signal?: AbortSignal,\n) => {\n return customInstance<UsersGetResponse>(\n { url: `/unit/${unitId}/user`, method: \"GET\", signal },\n options,\n );\n};\n\nexport const getGetOrganisationUnitUsersQueryKey = (unitId?: string) => {\n return [\"account-server\", \"unit\", unitId, \"user\"] as const;\n};\n\nexport const getGetOrganisationUnitUsersQueryOptions = <\n TData = Awaited<ReturnType<typeof getOrganisationUnitUsers>>,\n TError = ErrorType<AsError | void>,\n>(\n unitId: string,\n options?: {\n query?: UseQueryOptions<Awaited<ReturnType<typeof getOrganisationUnitUsers>>, TError, TData>;\n request?: SecondParameter<typeof customInstance>;\n },\n) => {\n const { query: queryOptions, request: requestOptions } = options ?? {};\n\n const queryKey = queryOptions?.queryKey ?? getGetOrganisationUnitUsersQueryKey(unitId);\n\n const queryFn: QueryFunction<Awaited<ReturnType<typeof getOrganisationUnitUsers>>> = ({\n signal,\n }) => getOrganisationUnitUsers(unitId, requestOptions, signal);\n\n return { queryKey, queryFn, enabled: !!unitId, ...queryOptions } as UseQueryOptions<\n Awaited<ReturnType<typeof getOrganisationUnitUsers>>,\n TError,\n TData\n > & { queryKey: QueryKey };\n};\n\nexport type GetOrganisationUnitUsersQueryResult = NonNullable<\n Awaited<ReturnType<typeof getOrganisationUnitUsers>>\n>;\nexport type GetOrganisationUnitUsersQueryError = ErrorType<AsError | void>;\n\n/**\n * @summary Gets users in an Organisational Unit\n */\n\nexport function useGetOrganisationUnitUsers<\n TData = Awaited<ReturnType<typeof getOrganisationUnitUsers>>,\n TError = ErrorType<AsError | void>,\n>(\n unitId: string,\n options?: {\n query?: UseQueryOptions<Awaited<ReturnType<typeof getOrganisationUnitUsers>>, TError, TData>;\n request?: SecondParameter<typeof customInstance>;\n },\n): UseQueryResult<TData, TError> & { queryKey: QueryKey } {\n const queryOptions = getGetOrganisationUnitUsersQueryOptions(unitId, options);\n\n const query = useQuery(queryOptions) as UseQueryResult<TData, TError> & { queryKey: QueryKey };\n\n query.queryKey = queryOptions.queryKey;\n\n return query;\n}\n\n/**\n * @summary Gets users in an Organisational Unit\n */\nexport const invalidateGetOrganisationUnitUsers = async (\n queryClient: QueryClient,\n unitId: string,\n options?: InvalidateOptions,\n): Promise<QueryClient> => {\n await queryClient.invalidateQueries(\n { queryKey: getGetOrganisationUnitUsersQueryKey(unitId) },\n options,\n );\n\n return queryClient;\n};\n\nexport const getGetOrganisationUnitUsersSuspenseQueryOptions = <\n TData = Awaited<ReturnType<typeof getOrganisationUnitUsers>>,\n TError = ErrorType<AsError | void>,\n>(\n unitId: string,\n options?: {\n query?: UseSuspenseQueryOptions<\n Awaited<ReturnType<typeof getOrganisationUnitUsers>>,\n TError,\n TData\n >;\n request?: SecondParameter<typeof customInstance>;\n },\n) => {\n const { query: queryOptions, request: requestOptions } = options ?? {};\n\n const queryKey = queryOptions?.queryKey ?? getGetOrganisationUnitUsersQueryKey(unitId);\n\n const queryFn: QueryFunction<Awaited<ReturnType<typeof getOrganisationUnitUsers>>> = ({\n signal,\n }) => getOrganisationUnitUsers(unitId, requestOptions, signal);\n\n return { queryKey, queryFn, ...queryOptions } as UseSuspenseQueryOptions<\n Awaited<ReturnType<typeof getOrganisationUnitUsers>>,\n TError,\n TData\n > & { queryKey: QueryKey };\n};\n\nexport type GetOrganisationUnitUsersSuspenseQueryResult = NonNullable<\n Awaited<ReturnType<typeof getOrganisationUnitUsers>>\n>;\nexport type GetOrganisationUnitUsersSuspenseQueryError = ErrorType<AsError | void>;\n\n/**\n * @summary Gets users in an Organisational Unit\n */\n\nexport function useGetOrganisationUnitUsersSuspense<\n TData = Awaited<ReturnType<typeof getOrganisationUnitUsers>>,\n TError = ErrorType<AsError | void>,\n>(\n unitId: string,\n options?: {\n query?: UseSuspenseQueryOptions<\n Awaited<ReturnType<typeof getOrganisationUnitUsers>>,\n TError,\n TData\n >;\n request?: SecondParameter<typeof customInstance>;\n },\n): UseSuspenseQueryResult<TData, TError> & { queryKey: QueryKey } {\n const queryOptions = getGetOrganisationUnitUsersSuspenseQueryOptions(unitId, options);\n\n const query = useSuspenseQuery(queryOptions) as UseSuspenseQueryResult<TData, TError> & {\n queryKey: QueryKey;\n };\n\n query.queryKey = queryOptions.queryKey;\n\n return query;\n}\n\n/**\n * Adds a user to an Organisational Unit.\n\nUsers cannot be added to **Personal Units** (Units that are part of the ***Default** Organisation).\n\nYou have to be in the Organisation or Unit or an Admin user to use this endpoint\n\n * @summary Adds a user to an Organisational Unit\n */\nexport const addOrganisationUnitUser = (\n unitId: string,\n userId: string,\n options?: SecondParameter<typeof customInstance>,\n) => {\n return customInstance<void>({ url: `/unit/${unitId}/user/${userId}`, method: \"PUT\" }, options);\n};\n\nexport const getAddOrganisationUnitUserMutationOptions = <\n TError = ErrorType<AsError | void>,\n TContext = unknown,\n>(options?: {\n mutation?: UseMutationOptions<\n Awaited<ReturnType<typeof addOrganisationUnitUser>>,\n TError,\n { unitId: string; userId: string },\n TContext\n >;\n request?: SecondParameter<typeof customInstance>;\n}): UseMutationOptions<\n Awaited<ReturnType<typeof addOrganisationUnitUser>>,\n TError,\n { unitId: string; userId: string },\n TContext\n> => {\n const mutationKey = [\"addOrganisationUnitUser\"];\n const { mutation: mutationOptions, request: requestOptions } = options\n ? options.mutation && \"mutationKey\" in options.mutation && options.mutation.mutationKey\n ? options\n : { ...options, mutation: { ...options.mutation, mutationKey } }\n : { mutation: { mutationKey }, request: undefined };\n\n const mutationFn: MutationFunction<\n Awaited<ReturnType<typeof addOrganisationUnitUser>>,\n { unitId: string; userId: string }\n > = (props) => {\n const { unitId, userId } = props ?? {};\n\n return addOrganisationUnitUser(unitId, userId, requestOptions);\n };\n\n return { mutationFn, ...mutationOptions };\n};\n\nexport type AddOrganisationUnitUserMutationResult = NonNullable<\n Awaited<ReturnType<typeof addOrganisationUnitUser>>\n>;\n\nexport type AddOrganisationUnitUserMutationError = ErrorType<AsError | void>;\n\n/**\n * @summary Adds a user to an Organisational Unit\n */\nexport const useAddOrganisationUnitUser = <\n TError = ErrorType<AsError | void>,\n TContext = unknown,\n>(options?: {\n mutation?: UseMutationOptions<\n Awaited<ReturnType<typeof addOrganisationUnitUser>>,\n TError,\n { unitId: string; userId: string },\n TContext\n >;\n request?: SecondParameter<typeof customInstance>;\n}): UseMutationResult<\n Awaited<ReturnType<typeof addOrganisationUnitUser>>,\n TError,\n { unitId: string; userId: string },\n TContext\n> => {\n const mutationOptions = getAddOrganisationUnitUserMutationOptions(options);\n\n return useMutation(mutationOptions);\n};\n/**\n * Removes a User from an Organisational Unit.\n\nUsers cannot be removed from **Personal Units** (Units that are part of the ***Default** Organisation).\n\nYou have to be in the Organisation or Unit or an Admin user to use this endpoint\n\n * @summary Deletes a User from an Organisational Unit\n */\nexport const deleteOrganisationUnitUser = (\n unitId: string,\n userId: string,\n options?: SecondParameter<typeof customInstance>,\n) => {\n return customInstance<void>({ url: `/unit/${unitId}/user/${userId}`, method: \"DELETE\" }, options);\n};\n\nexport const getDeleteOrganisationUnitUserMutationOptions = <\n TError = ErrorType<AsError | void>,\n TContext = unknown,\n>(options?: {\n mutation?: UseMutationOptions<\n Awaited<ReturnType<typeof deleteOrganisationUnitUser>>,\n TError,\n { unitId: string; userId: string },\n TContext\n >;\n request?: SecondParameter<typeof customInstance>;\n}): UseMutationOptions<\n Awaited<ReturnType<typeof deleteOrganisationUnitUser>>,\n TError,\n { unitId: string; userId: string },\n TContext\n> => {\n const mutationKey = [\"deleteOrganisationUnitUser\"];\n const { mutation: mutationOptions, request: requestOptions } = options\n ? options.mutation && \"mutationKey\" in options.mutation && options.mutation.mutationKey\n ? options\n : { ...options, mutation: { ...options.mutation, mutationKey } }\n : { mutation: { mutationKey }, request: undefined };\n\n const mutationFn: MutationFunction<\n Awaited<ReturnType<typeof deleteOrganisationUnitUser>>,\n { unitId: string; userId: string }\n > = (props) => {\n const { unitId, userId } = props ?? {};\n\n return deleteOrganisationUnitUser(unitId, userId, requestOptions);\n };\n\n return { mutationFn, ...mutationOptions };\n};\n\nexport type DeleteOrganisationUnitUserMutationResult = NonNullable<\n Awaited<ReturnType<typeof deleteOrganisationUnitUser>>\n>;\n\nexport type DeleteOrganisationUnitUserMutationError = ErrorType<AsError | void>;\n\n/**\n * @summary Deletes a User from an Organisational Unit\n */\nexport const useDeleteOrganisationUnitUser = <\n TError = ErrorType<AsError | void>,\n TContext = unknown,\n>(options?: {\n mutation?: UseMutationOptions<\n Awaited<ReturnType<typeof deleteOrganisationUnitUser>>,\n TError,\n { unitId: string; userId: string },\n TContext\n >;\n request?: SecondParameter<typeof customInstance>;\n}): UseMutationResult<\n Awaited<ReturnType<typeof deleteOrganisationUnitUser>>,\n TError,\n { unitId: string; userId: string },\n TContext\n> => {\n const mutationOptions = getDeleteOrganisationUnitUserMutationOptions(options);\n\n return useMutation(mutationOptions);\n};\n"],"mappings":"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"}
|
|
@@ -2,7 +2,7 @@ const require_rolldown_runtime = require('./_virtual/rolldown_runtime.cjs');
|
|
|
2
2
|
let axios = require("axios");
|
|
3
3
|
axios = require_rolldown_runtime.__toESM(axios);
|
|
4
4
|
|
|
5
|
-
//#region src/custom-
|
|
5
|
+
//#region src/custom-axios.ts
|
|
6
6
|
/** Based off the example custom-instance from Orval docs
|
|
7
7
|
* https://github.com/anymaniax/orval/blob/master/samples/react-app-with-react-query/src/api/mutator/custom-instance.ts
|
|
8
8
|
*
|
|
@@ -28,22 +28,14 @@ const setAuthToken = (token) => {
|
|
|
28
28
|
const setBaseUrl = (baseUrl) => {
|
|
29
29
|
AXIOS_INSTANCE.defaults.baseURL = baseUrl;
|
|
30
30
|
};
|
|
31
|
-
const customInstance = (config, options) => {
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
...options,
|
|
36
|
-
cancelToken: source.token
|
|
37
|
-
}).then(({ data }) => data);
|
|
38
|
-
promise.cancel = () => {
|
|
39
|
-
source.cancel("Query was cancelled");
|
|
40
|
-
};
|
|
41
|
-
return promise;
|
|
42
|
-
};
|
|
31
|
+
const customInstance = (config, options) => AXIOS_INSTANCE({
|
|
32
|
+
...config,
|
|
33
|
+
...options
|
|
34
|
+
}).then(({ data }) => data);
|
|
43
35
|
|
|
44
36
|
//#endregion
|
|
45
37
|
exports.AXIOS_INSTANCE = AXIOS_INSTANCE;
|
|
46
38
|
exports.customInstance = customInstance;
|
|
47
39
|
exports.setAuthToken = setAuthToken;
|
|
48
40
|
exports.setBaseUrl = setBaseUrl;
|
|
49
|
-
//# sourceMappingURL=custom-
|
|
41
|
+
//# sourceMappingURL=custom-axios.cjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"custom-axios.cjs","names":["Axios"],"sources":["../src/custom-axios.ts"],"sourcesContent":["/** Based off the example custom-instance from Orval docs\n * https://github.com/anymaniax/orval/blob/master/samples/react-app-with-react-query/src/api/mutator/custom-instance.ts\n *\n * See https://react-query.tanstack.com/guides/query-cancellation\n *\n * TODO: Considering using Fetch-API instead of axios. This instance will have to change. Could be\n * achieved without changing much using `redaxios`\n * Or use 'ky'\n */\n\nimport Axios, { AxiosError, type AxiosRequestConfig } from \"axios\";\n\nexport const AXIOS_INSTANCE = Axios.create();\n\n/**\n * Set the access token to be added as the `Authorization: Bearer 'token'` header\n * Useful for client only apps where a proxy API route isn't involved to securely add the access token\n * @param token access token\n */\nexport const setAuthToken = (token: string) => {\n AXIOS_INSTANCE.defaults.headers.common[\"Authorization\"] = `Bearer ${token}`;\n};\n\n/**\n * Set the url to which request paths are added to.\n * @param baseUrl origin + subpath e.g. 'https://example.com/subpath' or '/subpath'\n */\nexport const setBaseUrl = (baseUrl: string) => {\n AXIOS_INSTANCE.defaults.baseURL = baseUrl;\n};\n\nexport const customInstance = <TReturn>(\n config: AxiosRequestConfig,\n options?: AxiosRequestConfig,\n): Promise<TReturn> => AXIOS_INSTANCE({ ...config, ...options }).then(({ data }) => data);\n\nexport type ErrorType<TError> = AxiosError<TError>;\n"],"mappings":";;;;;;;;;;;;;;AAYA,MAAa,iBAAiBA,cAAM,QAAQ;;;;;;AAO5C,MAAa,gBAAgB,UAAkB;AAC7C,gBAAe,SAAS,QAAQ,OAAO,mBAAmB,UAAU;;;;;;AAOtE,MAAa,cAAc,YAAoB;AAC7C,gBAAe,SAAS,UAAU;;AAGpC,MAAa,kBACX,QACA,YACqB,eAAe;CAAE,GAAG;CAAQ,GAAG;CAAS,CAAC,CAAC,MAAM,EAAE,WAAW,KAAK"}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import * as axios0 from "axios";
|
|
2
2
|
import { AxiosError, AxiosRequestConfig } from "axios";
|
|
3
3
|
|
|
4
|
-
//#region src/custom-
|
|
4
|
+
//#region src/custom-axios.d.ts
|
|
5
5
|
|
|
6
6
|
declare const AXIOS_INSTANCE: axios0.AxiosInstance;
|
|
7
7
|
/**
|
|
@@ -19,4 +19,4 @@ declare const customInstance: <TReturn>(config: AxiosRequestConfig, options?: Ax
|
|
|
19
19
|
type ErrorType<TError> = AxiosError<TError>;
|
|
20
20
|
//#endregion
|
|
21
21
|
export { AXIOS_INSTANCE, ErrorType, customInstance, setAuthToken, setBaseUrl };
|
|
22
|
-
//# sourceMappingURL=custom-
|
|
22
|
+
//# sourceMappingURL=custom-axios.d.cts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"custom-axios.d.cts","names":[],"sources":["../src/custom-axios.ts"],"sourcesContent":[],"mappings":";;;;;AAkCW,cAtBE,cAsBF,EAtBiC,MAAA,CAAjB,aAsBhB;;;AAEX;;;cAjBa;;;;;cAQA;cAIA,kCACH,8BACE,uBACT,QAAQ;KAEC,oBAAoB,WAAW"}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import * as axios0 from "axios";
|
|
2
2
|
import { AxiosError, AxiosRequestConfig } from "axios";
|
|
3
3
|
|
|
4
|
-
//#region src/custom-
|
|
4
|
+
//#region src/custom-axios.d.ts
|
|
5
5
|
|
|
6
6
|
declare const AXIOS_INSTANCE: axios0.AxiosInstance;
|
|
7
7
|
/**
|
|
@@ -19,4 +19,4 @@ declare const customInstance: <TReturn>(config: AxiosRequestConfig, options?: Ax
|
|
|
19
19
|
type ErrorType<TError> = AxiosError<TError>;
|
|
20
20
|
//#endregion
|
|
21
21
|
export { AXIOS_INSTANCE, ErrorType, customInstance, setAuthToken, setBaseUrl };
|
|
22
|
-
//# sourceMappingURL=custom-
|
|
22
|
+
//# sourceMappingURL=custom-axios.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"custom-axios.d.ts","names":[],"sources":["../src/custom-axios.ts"],"sourcesContent":[],"mappings":";;;;;AAkCW,cAtBE,cAsBF,EAtBiC,MAAA,CAAjB,aAsBhB;;;AAEX;;;cAjBa;;;;;cAQA;cAIA,kCACH,8BACE,uBACT,QAAQ;KAEC,oBAAoB,WAAW"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import Axios, { AxiosError } from "axios";
|
|
2
2
|
|
|
3
|
-
//#region src/custom-
|
|
3
|
+
//#region src/custom-axios.ts
|
|
4
4
|
/** Based off the example custom-instance from Orval docs
|
|
5
5
|
* https://github.com/anymaniax/orval/blob/master/samples/react-app-with-react-query/src/api/mutator/custom-instance.ts
|
|
6
6
|
*
|
|
@@ -26,19 +26,11 @@ const setAuthToken = (token) => {
|
|
|
26
26
|
const setBaseUrl = (baseUrl) => {
|
|
27
27
|
AXIOS_INSTANCE.defaults.baseURL = baseUrl;
|
|
28
28
|
};
|
|
29
|
-
const customInstance = (config, options) => {
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
...options,
|
|
34
|
-
cancelToken: source.token
|
|
35
|
-
}).then(({ data }) => data);
|
|
36
|
-
promise.cancel = () => {
|
|
37
|
-
source.cancel("Query was cancelled");
|
|
38
|
-
};
|
|
39
|
-
return promise;
|
|
40
|
-
};
|
|
29
|
+
const customInstance = (config, options) => AXIOS_INSTANCE({
|
|
30
|
+
...config,
|
|
31
|
+
...options
|
|
32
|
+
}).then(({ data }) => data);
|
|
41
33
|
|
|
42
34
|
//#endregion
|
|
43
35
|
export { AXIOS_INSTANCE, customInstance, setAuthToken, setBaseUrl };
|
|
44
|
-
//# sourceMappingURL=custom-
|
|
36
|
+
//# sourceMappingURL=custom-axios.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"custom-axios.js","names":[],"sources":["../src/custom-axios.ts"],"sourcesContent":["/** Based off the example custom-instance from Orval docs\n * https://github.com/anymaniax/orval/blob/master/samples/react-app-with-react-query/src/api/mutator/custom-instance.ts\n *\n * See https://react-query.tanstack.com/guides/query-cancellation\n *\n * TODO: Considering using Fetch-API instead of axios. This instance will have to change. Could be\n * achieved without changing much using `redaxios`\n * Or use 'ky'\n */\n\nimport Axios, { AxiosError, type AxiosRequestConfig } from \"axios\";\n\nexport const AXIOS_INSTANCE = Axios.create();\n\n/**\n * Set the access token to be added as the `Authorization: Bearer 'token'` header\n * Useful for client only apps where a proxy API route isn't involved to securely add the access token\n * @param token access token\n */\nexport const setAuthToken = (token: string) => {\n AXIOS_INSTANCE.defaults.headers.common[\"Authorization\"] = `Bearer ${token}`;\n};\n\n/**\n * Set the url to which request paths are added to.\n * @param baseUrl origin + subpath e.g. 'https://example.com/subpath' or '/subpath'\n */\nexport const setBaseUrl = (baseUrl: string) => {\n AXIOS_INSTANCE.defaults.baseURL = baseUrl;\n};\n\nexport const customInstance = <TReturn>(\n config: AxiosRequestConfig,\n options?: AxiosRequestConfig,\n): Promise<TReturn> => AXIOS_INSTANCE({ ...config, ...options }).then(({ data }) => data);\n\nexport type ErrorType<TError> = AxiosError<TError>;\n"],"mappings":";;;;;;;;;;;;AAYA,MAAa,iBAAiB,MAAM,QAAQ;;;;;;AAO5C,MAAa,gBAAgB,UAAkB;AAC7C,gBAAe,SAAS,QAAQ,OAAO,mBAAmB,UAAU;;;;;;AAOtE,MAAa,cAAc,YAAoB;AAC7C,gBAAe,SAAS,UAAU;;AAGpC,MAAa,kBACX,QACA,YACqB,eAAe;CAAE,GAAG;CAAQ,GAAG;CAAS,CAAC,CAAC,MAAM,EAAE,WAAW,KAAK"}
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
|
|
2
|
+
//#region src/custom-fetch.ts
|
|
3
|
+
let baseURL = "";
|
|
4
|
+
/**
|
|
5
|
+
* Custom fetch wrapper that prepends the base URL
|
|
6
|
+
* Compatible with Orval's generated RequestInit spreading
|
|
7
|
+
*/
|
|
8
|
+
const customFetch = async (url, options) => {
|
|
9
|
+
const { params, ...requestInit } = options ?? {};
|
|
10
|
+
let targetUrl = `${baseURL}${url}`;
|
|
11
|
+
if (params) targetUrl += "?" + new URLSearchParams(params);
|
|
12
|
+
const processedBody = requestInit.body && typeof requestInit.body === "object" ? JSON.stringify(requestInit.body) : requestInit.body;
|
|
13
|
+
const response = await fetch(targetUrl, {
|
|
14
|
+
...requestInit,
|
|
15
|
+
body: processedBody,
|
|
16
|
+
headers: {
|
|
17
|
+
"Content-Type": "application/json",
|
|
18
|
+
...requestInit.headers
|
|
19
|
+
}
|
|
20
|
+
});
|
|
21
|
+
if (!response.ok) throw response;
|
|
22
|
+
if ([
|
|
23
|
+
204,
|
|
24
|
+
205,
|
|
25
|
+
304
|
|
26
|
+
].includes(response.status)) return {};
|
|
27
|
+
return response.json();
|
|
28
|
+
};
|
|
29
|
+
|
|
30
|
+
//#endregion
|
|
31
|
+
exports.customFetch = customFetch;
|
|
32
|
+
//# sourceMappingURL=custom-fetch.cjs.map
|