@squonk/account-server-client 2.4.1-rc.1 → 3.0.0-rc.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (42) hide show
  1. package/charges/charges.cjs +188 -0
  2. package/charges/charges.cjs.map +1 -0
  3. package/charges/charges.d.cts +184 -0
  4. package/charges/charges.d.ts +184 -0
  5. package/charges/charges.js +188 -0
  6. package/charges/charges.js.map +1 -0
  7. package/index.cjs.map +1 -1
  8. package/index.d.cts +2 -2
  9. package/index.d.ts +2 -2
  10. package/index.js.map +1 -1
  11. package/organisation/organisation.cjs +1 -45
  12. package/organisation/organisation.cjs.map +1 -1
  13. package/organisation/organisation.d.cts +5 -48
  14. package/organisation/organisation.d.ts +5 -48
  15. package/organisation/organisation.js +0 -44
  16. package/organisation/organisation.js.map +1 -1
  17. package/package.json +1 -1
  18. package/product/product.cjs +1 -45
  19. package/product/product.cjs.map +1 -1
  20. package/product/product.d.cts +2 -48
  21. package/product/product.d.ts +2 -48
  22. package/product/product.js +0 -44
  23. package/product/product.js.map +1 -1
  24. package/src/account-server-api.schemas.ts +2 -2
  25. package/src/charges/charges.ts +487 -0
  26. package/src/organisation/organisation.ts +0 -114
  27. package/src/product/product.ts +1 -117
  28. package/src/unit/unit.ts +1 -116
  29. package/unit/unit.cjs +1 -45
  30. package/unit/unit.cjs.map +1 -1
  31. package/unit/unit.d.cts +2 -47
  32. package/unit/unit.d.ts +2 -47
  33. package/unit/unit.js +0 -44
  34. package/unit/unit.js.map +1 -1
  35. package/admin/admin.cjs +0 -56
  36. package/admin/admin.cjs.map +0 -1
  37. package/admin/admin.d.cts +0 -50
  38. package/admin/admin.d.ts +0 -50
  39. package/admin/admin.js +0 -56
  40. package/admin/admin.js.map +0 -1
  41. package/admin/package.json +0 -7
  42. package/src/admin/admin.ts +0 -140
package/index.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"sources":["../src/account-server-api.schemas.ts"],"sourcesContent":["/**\n * Generated by orval v6.25.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: 2.4\n */\nexport type DetachAssetParams = {\n/**\n * A Merchant Identity\n */\nm_id?: QMIdParameter;\n};\n\nexport type AttachAssetParams = {\n/**\n * A Merchant Identity\n */\nm_id?: QMIdParameter;\n};\n\n/**\n * A date where assets prior to this will be returned. This can be a date-time string but it is interpreted as a date, i.e. `2020-01-01T00:00:00Z` is interpreted as `2020-01-01`. Any asset that occurs prior this date will be returned. UTC is assumed if no timezone is provided\n */\nexport type QUntilParameter = string;\n\n/**\n * A date from which to retrieve assets. This can be a date-time string but it is interpreted as a date, i.e. `2020-01-01T00:00:00Z` is interpreted as `2020-01-01`. Any asset that occurs on ar after this date will be returned. UTC is assumed if no timezone is provided\n */\nexport type QFromParameter = string;\n\nexport type GetUnitChargesParams = {\n/**\n * A date from which to retrieve assets. This can be a date-time string but it is interpreted as a date, i.e. `2020-01-01T00:00:00Z` is interpreted as `2020-01-01`. Any asset that occurs on ar after this date will be returned. UTC is assumed if no timezone is provided\n */\nfrom?: QFromParameter;\n/**\n * A date where assets prior to this will be returned. This can be a date-time string but it is interpreted as a date, i.e. `2020-01-01T00:00:00Z` is interpreted as `2020-01-01`. Any asset that occurs prior this date will be returned. UTC is assumed if no timezone is provided\n */\nuntil?: QUntilParameter;\n/**\n * A charge Prior Billing Period, 0 implies \"current\" and -23 is for the period 23 months ago.\n */\npbp?: QPbpParameter;\n};\n\nexport type GetOrganisationChargesParams = {\n/**\n * A date from which to retrieve assets. This can be a date-time string but it is interpreted as a date, i.e. `2020-01-01T00:00:00Z` is interpreted as `2020-01-01`. Any asset that occurs on ar after this date will be returned. UTC is assumed if no timezone is provided\n */\nfrom?: QFromParameter;\n/**\n * A date where assets prior to this will be returned. This can be a date-time string but it is interpreted as a date, i.e. `2020-01-01T00:00:00Z` is interpreted as `2020-01-01`. Any asset that occurs prior this date will be returned. UTC is assumed if no timezone is provided\n */\nuntil?: QUntilParameter;\n/**\n * A charge Prior Billing Period, 0 implies \"current\" and -23 is for the period 23 months ago.\n */\npbp?: QPbpParameter;\n};\n\nexport type GetProductChargesParams = {\n/**\n * A date from which to retrieve assets. This can be a date-time string but it is interpreted as a date, i.e. `2020-01-01T00:00:00Z` is interpreted as `2020-01-01`. Any asset that occurs on ar after this date will be returned. UTC is assumed if no timezone is provided\n */\nfrom?: QFromParameter;\n/**\n * A date where assets prior to this will be returned. This can be a date-time string but it is interpreted as a date, i.e. `2020-01-01T00:00:00Z` is interpreted as `2020-01-01`. Any asset that occurs prior this date will be returned. UTC is assumed if no timezone is provided\n */\nuntil?: QUntilParameter;\n/**\n * A charge Prior Billing Period, 0 implies \"current\" and -23 is for the period 23 months ago.\n */\npbp?: QPbpParameter;\n};\n\nexport type GetChargesParams = {\n/**\n * A date from which to retrieve assets. This can be a date-time string but it is interpreted as a date, i.e. `2020-01-01T00:00:00Z` is interpreted as `2020-01-01`. Any asset that occurs on ar after this date will be returned. UTC is assumed if no timezone is provided\n */\nfrom?: QFromParameter;\n/**\n * A date where assets prior to this will be returned. This can be a date-time string but it is interpreted as a date, i.e. `2020-01-01T00:00:00Z` is interpreted as `2020-01-01`. Any asset that occurs prior this date will be returned. UTC is assumed if no timezone is provided\n */\nuntil?: QUntilParameter;\n/**\n * A charge Prior Billing Period, 0 implies \"current\" and -23 is for the period 23 months ago.\n */\npbp?: QPbpParameter;\n};\n\n/**\n * A User Identity\n */\nexport type QUserIdParameter = string;\n\n/**\n * A Product Identity\n */\nexport type QProductIdParameter = string;\n\n/**\n * A Unit Identity\n */\nexport type QUnitIdParameter = string;\n\nexport type GetAssetParams = {\n/**\n * A User Identity\n */\nuser_id?: QUserIdParameter;\n/**\n * A Product Identity\n */\nproduct_id?: QProductIdParameter;\n/**\n * A Unit Identity\n */\nunit_id?: QUnitIdParameter;\n/**\n * An Organisation Identity\n */\norg_id?: QOrgIdParameter;\n};\n\n/**\n * A Merchant Identity\n */\nexport type QMIdParameter = number;\n\n/**\n * An Organisation Identity\n */\nexport type QOrgIdParameter = string;\n\n/**\n * A charge Prior Billing Period, 0 implies \"current\" and -23 is for the period 23 months ago.\n */\nexport type QPbpParameter = number;\n\nexport type ProductPatchBodyBody = {\n /** The Product's built-in coin allowance. Product allowances cannot be reduced */\n allowance?: number;\n /** The Product's built-in coin limit. If set it must not be less than the allowance. If not set the allowance is used. The existing product limit cannot be reduced */\n limit?: number;\n /** The name you want to give the Product */\n name?: string;\n};\n\n/**\n * The Type of Product. Storage subscriptions require an **Allowance** to be defined and the **Flavour** must not be provided.\n\nProject Tier subscriptions have built-in allowances and Limits so you must not provide values for these for these products\n */\nexport type UnitProductPostBodyBodyType = typeof UnitProductPostBodyBodyType[keyof typeof UnitProductPostBodyBodyType];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const UnitProductPostBodyBodyType = {\n DATA_MANAGER_PROJECT_TIER_SUBSCRIPTION: 'DATA_MANAGER_PROJECT_TIER_SUBSCRIPTION',\n DATA_MANAGER_STORAGE_SUBSCRIPTION: 'DATA_MANAGER_STORAGE_SUBSCRIPTION',\n} as const;\n\n/**\n * The Flavour of the Product. Used only for Project Tier Products. Do not set this for Storage products\n */\nexport type UnitProductPostBodyBodyFlavour = typeof UnitProductPostBodyBodyFlavour[keyof typeof UnitProductPostBodyBodyFlavour];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const UnitProductPostBodyBodyFlavour = {\n EVALUATION: 'EVALUATION',\n BRONZE: 'BRONZE',\n SILVER: 'SILVER',\n GOLD: 'GOLD',\n} as const;\n\nexport type UnitProductPostBodyBody = {\n /** The Product's coin allowance. You must provide this for Storage products but you must not provide a value for Project Tier Products */\n allowance?: number;\n /** The Flavour of the Product. Used only for Project Tier Products. Do not set this for Storage products */\n flavour?: UnitProductPostBodyBodyFlavour;\n /** The Product's built-in coin limit. If set it must not be less than the allowance. If not set the allowance is used. You can provide this for Storage products but you must not provide a value for Project Tier Products */\n limit?: number;\n /** The name you want to give the Product */\n name: string;\n /** The Type of Product. Storage subscriptions require an **Allowance** to be defined and the **Flavour** must not be provided.\n\nProject Tier subscriptions have built-in allowances and Limits so you must not provide values for these for these products */\n type: UnitProductPostBodyBodyType;\n};\n\n/**\n * The new default **Product** privacy applied to all products that belong to this Unit. Privacy is also controlled at the **Organisation** level. As an example, the Unit can declare its Products to be `DEFAULT_PRIVATE`, but the Organisation can declare its value to be `DEFAULT_PUBLIC`.\n\nWhether the privacy can be honoured will depend on the organisation's value\n */\nexport type UnitPatchBodyBodyDefaultProductPrivacy = typeof UnitPatchBodyBodyDefaultProductPrivacy[keyof typeof UnitPatchBodyBodyDefaultProductPrivacy];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const UnitPatchBodyBodyDefaultProductPrivacy = {\n ALWAYS_PUBLIC: 'ALWAYS_PUBLIC',\n ALWAYS_PRIVATE: 'ALWAYS_PRIVATE',\n DEFAULT_PUBLIC: 'DEFAULT_PUBLIC',\n DEFAULT_PRIVATE: 'DEFAULT_PRIVATE',\n} as const;\n\nexport type UnitPatchBodyBody = {\n /** The new default **Product** privacy applied to all products that belong to this Unit. Privacy is also controlled at the **Organisation** level. As an example, the Unit can declare its Products to be `DEFAULT_PRIVATE`, but the Organisation can declare its value to be `DEFAULT_PUBLIC`.\n\nWhether the privacy can be honoured will depend on the organisation's value */\n default_product_privacy?: UnitPatchBodyBodyDefaultProductPrivacy;\n /** The new name for the Unit */\n name?: string;\n};\n\n/**\n * The new default **Product** privacy applied to all products that belong to this Organisation. Privacy is also controlled at the **Unit** level. As an example the Organisation level privacy can be `DEFAULT_PRIVATE`, but the unit can declare its Products to be `ALWAYS_PRIVATE`.\n\nWhether the privacy can be honoured will depend on the value in any of the organisation's existing units\n */\nexport type OrganisationPatchBodyBodyDefaultProductPrivacy = typeof OrganisationPatchBodyBodyDefaultProductPrivacy[keyof typeof OrganisationPatchBodyBodyDefaultProductPrivacy];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const OrganisationPatchBodyBodyDefaultProductPrivacy = {\n ALWAYS_PUBLIC: 'ALWAYS_PUBLIC',\n ALWAYS_PRIVATE: 'ALWAYS_PRIVATE',\n DEFAULT_PUBLIC: 'DEFAULT_PUBLIC',\n DEFAULT_PRIVATE: 'DEFAULT_PRIVATE',\n} as const;\n\nexport type OrganisationPatchBodyBody = {\n /** The new default **Product** privacy applied to all products that belong to this Organisation. Privacy is also controlled at the **Unit** level. As an example the Organisation level privacy can be `DEFAULT_PRIVATE`, but the unit can declare its Products to be `ALWAYS_PRIVATE`.\n\nWhether the privacy can be honoured will depend on the value in any of the organisation's existing units */\n default_product_privacy?: OrganisationPatchBodyBodyDefaultProductPrivacy;\n /** The new name for the Organisational */\n name?: string;\n};\n\n/**\n * The default product privacy setting for products in the unit. Whether the privacy can be honoured will depend on the organisation's value\n */\nexport type OrganisationUnitPostBodyBodyDefaultProductPrivacy = typeof OrganisationUnitPostBodyBodyDefaultProductPrivacy[keyof typeof OrganisationUnitPostBodyBodyDefaultProductPrivacy];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const OrganisationUnitPostBodyBodyDefaultProductPrivacy = {\n ALWAYS_PUBLIC: 'ALWAYS_PUBLIC',\n ALWAYS_PRIVATE: 'ALWAYS_PRIVATE',\n DEFAULT_PUBLIC: 'DEFAULT_PUBLIC',\n DEFAULT_PRIVATE: 'DEFAULT_PRIVATE',\n} as const;\n\nexport type OrganisationUnitPostBodyBody = {\n /** The day you would like to be billed for the Unit's Products (a value from 1 and 28) */\n billing_day: number;\n /** The default product privacy setting for products in the unit. Whether the privacy can be honoured will depend on the organisation's value */\n default_product_privacy?: OrganisationUnitPostBodyBodyDefaultProductPrivacy;\n /** The name of the unit */\n name: string;\n};\n\nexport type PersonalUnitPutBodyBody = {\n /** The day you would like to be billed for the Unit's Products (a value from 1 and 28) */\n billing_day: number;\n};\n\n/**\n * The default product privacy setting for the Organisation\n */\nexport type OrganisationPostBodyBodyDefaultProductPrivacy = typeof OrganisationPostBodyBodyDefaultProductPrivacy[keyof typeof OrganisationPostBodyBodyDefaultProductPrivacy];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const OrganisationPostBodyBodyDefaultProductPrivacy = {\n ALWAYS_PUBLIC: 'ALWAYS_PUBLIC',\n ALWAYS_PRIVATE: 'ALWAYS_PRIVATE',\n DEFAULT_PUBLIC: 'DEFAULT_PUBLIC',\n DEFAULT_PRIVATE: 'DEFAULT_PRIVATE',\n} as const;\n\nexport type OrganisationPostBodyBody = {\n /** The default product privacy setting for the Organisation */\n default_product_privacy?: OrganisationPostBodyBodyDefaultProductPrivacy;\n /** The name of the organisation */\n name: string;\n /** The name of the organisation owner. A user ID */\n owner: string;\n};\n\nexport type AssetPostBodyBodyScope = typeof AssetPostBodyBodyScope[keyof typeof AssetPostBodyBodyScope];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const AssetPostBodyBodyScope = {\n USER: 'USER',\n PRODUCT: 'PRODUCT',\n UNIT: 'UNIT',\n ORGANISATION: 'ORGANISATION',\n GLOBAL: 'GLOBAL',\n} as const;\n\nexport type AssetPostBodyBody = {\n /** A file containing the content for the asset. You must provide a value here or in content_string */\n content_file?: Blob;\n /** The textual content of the asset. You must provide a value here or in content_file */\n content_string?: string;\n /** An optional description for the Asset */\n description?: string;\n /** The name of the asset. This must be unique within its scope. For example, only one asset can be called \"asset-1\" within a given Unit. Asset names must be valid RFC 1123 Label Names */\n name: string;\n scope: AssetPostBodyBodyScope;\n /** The unique identity based on the Scope of the asset. For example, this will be the Unit ID if it's a UNIT. A scope_id is required if the scope is USER as it will be automatically set to your username. Global assets do not have a scope. */\n scope_id?: string;\n /** Is this a secret asset? */\n secret: boolean;\n};\n\nexport type AssetPatchBodyBody = {\n /** A file containing the content for the asset. You must provide a value here or in content_string */\n content_file?: Blob;\n /** The textual content of the asset. You must provide a value here or in content_file */\n content_string?: string;\n /** An optional description for the Asset */\n description?: string;\n};\n\nexport interface UserDetail {\n /** The user identity (username) */\n id: string;\n}\n\nexport interface UserAccountDetail {\n /** The roles assigned to the user recognised by the Account Server */\n account_server_roles: string[];\n /** Whether the caller has admin privilege */\n caller_has_admin_privilege: boolean;\n user: UserDetail;\n}\n\n/**\n * The Unit's default product privacy setting\n */\nexport type UnitDetailDefaultProductPrivacy = typeof UnitDetailDefaultProductPrivacy[keyof typeof UnitDetailDefaultProductPrivacy];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const UnitDetailDefaultProductPrivacy = {\n ALWAYS_PUBLIC: 'ALWAYS_PUBLIC',\n ALWAYS_PRIVATE: 'ALWAYS_PRIVATE',\n DEFAULT_PUBLIC: 'DEFAULT_PUBLIC',\n DEFAULT_PRIVATE: 'DEFAULT_PRIVATE',\n} as const;\n\nexport interface UnitDetail {\n /** The Unit's billing day */\n billing_day: number;\n /** Whether the user making the API call is a member of the Unit */\n caller_is_member: boolean;\n created: string;\n /** The Unit's default product privacy setting */\n default_product_privacy: UnitDetailDefaultProductPrivacy;\n /** The Unit's unique identity */\n id: string;\n /** The Unit's name */\n name: string;\n /** The Unit's owner (a username) */\n owner_id: string;\n /** True if the Unit is private */\n private: boolean;\n}\n\n/**\n * The Unit's default product privacy setting\n */\nexport type UnitAllDetailDefaultProductPrivacy = typeof UnitAllDetailDefaultProductPrivacy[keyof typeof UnitAllDetailDefaultProductPrivacy];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const UnitAllDetailDefaultProductPrivacy = {\n ALWAYS_PUBLIC: 'ALWAYS_PUBLIC',\n ALWAYS_PRIVATE: 'ALWAYS_PRIVATE',\n DEFAULT_PUBLIC: 'DEFAULT_PUBLIC',\n DEFAULT_PRIVATE: 'DEFAULT_PRIVATE',\n} as const;\n\nexport interface UnitAllDetail {\n /** The Unit's billing day */\n billing_day: number;\n /** Whether the user making the API call is a member of the Unit */\n caller_is_member: boolean;\n created: string;\n /** The Unit's default product privacy setting */\n default_product_privacy: UnitAllDetailDefaultProductPrivacy;\n /** The Unit's unique identity */\n id: string;\n /** The Unit's name */\n name: string;\n /** The Unit's owner (a username) */\n owner_id: string;\n /** True if the Unit is private */\n private: boolean;\n /** A list of users that are members of the Unit */\n users: UserDetail[];\n}\n\n/**\n * The kind of Service\n */\nexport type MerchantDetailKind = typeof MerchantDetailKind[keyof typeof MerchantDetailKind];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const MerchantDetailKind = {\n DATA_MANAGER: 'DATA_MANAGER',\n} as const;\n\nexport interface MerchantDetail {\n /** The hostname used by the Service */\n api_hostname: string;\n created: string;\n /** The unique ID of the Service */\n id: number;\n /** The kind of Service */\n kind: MerchantDetailKind;\n /** The name assigned to the Service */\n name: string;\n}\n\nexport type MerchantGetResponse = MerchantDetail;\n\nexport interface MerchantsGetResponse {\n count?: number;\n /** The list of known Merchants\n */\n merchants: MerchantDetail[];\n}\n\n/**\n * The Organisation's default product privacy setting\n */\nexport type OrganisationDetailDefaultProductPrivacy = typeof OrganisationDetailDefaultProductPrivacy[keyof typeof OrganisationDetailDefaultProductPrivacy];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const OrganisationDetailDefaultProductPrivacy = {\n ALWAYS_PUBLIC: 'ALWAYS_PUBLIC',\n ALWAYS_PRIVATE: 'ALWAYS_PRIVATE',\n DEFAULT_PUBLIC: 'DEFAULT_PUBLIC',\n DEFAULT_PRIVATE: 'DEFAULT_PRIVATE',\n} as const;\n\nexport interface OrganisationDetail {\n /** Whether the user making the API call is a member of the Unit */\n caller_is_member: boolean;\n created: string;\n /** The Organisation's default product privacy setting */\n default_product_privacy: OrganisationDetailDefaultProductPrivacy;\n /** The Organisation's unique ID */\n id: string;\n /** The Organisation's name */\n name: string;\n /** The username of the Organisation's owner. Not all Organisations have an owner. The Default Organisation has no owner. */\n owner_id?: string;\n /** True if the Unit is private */\n private: boolean;\n}\n\n/**\n * The Organisation's default product privacy setting\n */\nexport type OrganisationAllDetailDefaultProductPrivacy = typeof OrganisationAllDetailDefaultProductPrivacy[keyof typeof OrganisationAllDetailDefaultProductPrivacy];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const OrganisationAllDetailDefaultProductPrivacy = {\n ALWAYS_PUBLIC: 'ALWAYS_PUBLIC',\n ALWAYS_PRIVATE: 'ALWAYS_PRIVATE',\n DEFAULT_PUBLIC: 'DEFAULT_PUBLIC',\n DEFAULT_PRIVATE: 'DEFAULT_PRIVATE',\n} as const;\n\nexport interface OrganisationAllDetail {\n /** Whether the user making the API call is a member of the Unit */\n caller_is_member: boolean;\n created: string;\n /** The Organisation's default product privacy setting */\n default_product_privacy: OrganisationAllDetailDefaultProductPrivacy;\n /** The Organisation's unique ID */\n id: string;\n /** The Organisation's name */\n name: string;\n /** The username of the Organisation's owner. Not all Organisations have an owner. The Default Organisation has no owner. */\n owner_id?: string;\n /** True if the Unit is private */\n private: boolean;\n /** A list of users that are members of the Organisation */\n users: UserDetail[];\n}\n\n/**\n * The kind of service that can use the Product\n */\nexport type ProductTypeServiceKind = typeof ProductTypeServiceKind[keyof typeof ProductTypeServiceKind];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const ProductTypeServiceKind = {\n DATA_MANAGER: 'DATA_MANAGER',\n} as const;\n\nexport interface ProductType {\n /** A product flavour. Not all types have a flavour, those that do have a type-specific flavour string */\n flavour?: string;\n /** The kind of service that can use the Product */\n service_kind?: ProductTypeServiceKind;\n /** A product type, this is a unique string amongst all types known to the Account Server */\n type: string;\n}\n\nexport type ProductInstanceDetailCoins = {\n /** The number of coins used\n */\n used: number;\n};\n\nexport interface ProductInstanceDetail {\n coins: ProductInstanceDetailCoins;\n}\n\n/**\n * The Product Type\n\n */\nexport type ProductDetailType = typeof ProductDetailType[keyof typeof ProductDetailType];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const ProductDetailType = {\n DATA_MANAGER_PROJECT_TIER_SUBSCRIPTION: 'DATA_MANAGER_PROJECT_TIER_SUBSCRIPTION',\n DATA_MANAGER_STORAGE_SUBSCRIPTION: 'DATA_MANAGER_STORAGE_SUBSCRIPTION',\n} as const;\n\n/**\n * The Product Type flavour. Not all products have flavours\n\n */\nexport type ProductDetailFlavour = typeof ProductDetailFlavour[keyof typeof ProductDetailFlavour];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const ProductDetailFlavour = {\n EVALUATION: 'EVALUATION',\n BRONZE: 'BRONZE',\n SILVER: 'SILVER',\n GOLD: 'GOLD',\n} as const;\n\nexport interface ProductDetail {\n created: string;\n /** The Product Type flavour. Not all products have flavours\n */\n flavour?: ProductDetailFlavour;\n /** The Product ID\n */\n id: string;\n /** The name of the Product\n */\n name?: string;\n /** The Product Type\n */\n type: ProductDetailType;\n}\n\nexport interface ProductCoinsDetail {\n /** The billing allowance. When you exceed this during the current billing period the *cost multiplier* will increase */\n allowance: number;\n /** A multiplier applied to your coin usage within your allowance */\n allowance_multiplier: number;\n /** True if the product is operating at or beyond its coin limit. When it is authority to perform actions using the product are severely limited. */\n at_limit: boolean;\n /** The day of the month when the bill is due, and the end of the current billing period */\n billing_day: number;\n /** The predicted total billing period amount, if costs continue at the current burn rate until the end of the billing period. This is an estimate */\n billing_prediction: number;\n /** The predicted storage contribution to the billing period amount, if costs continue at the current burn rate until the end of the billing period. This is an estimate */\n billing_prediction_storage_contribution: number;\n /** The current burn rate, the approximate amount of coins you are currently consuming each day */\n current_burn_rate: number;\n /** The limit on your billing period spend. You can exceed the allowance but you cannot exceed the spend limit. Once reached the dependent may be restricted */\n limit: number;\n /** A multiplier that will be applied to coin used beyond your allowance */\n overspend_multiplier: number;\n /** The number of days remaining, in the current billing period */\n remaining_days: number;\n /** The total number of coins consumed (in this billing period), excluding the coins that have been consumed for the current day */\n used: number;\n}\n\nexport interface ProductClaimDetail {\n /** The service-specific ID that is using this Subscription\n */\n id: string;\n /** A name for the service-specific ID\n */\n name?: string;\n}\n\nexport type ProductDmStorageDetailSize = {\n /** The humanised size of the current storage used for the current day and used to calculate the 'burn rate' */\n current: string;\n /** The humanised size of the peak storage used for the current day. The value is reset at the start of each day */\n peak: string;\n /** The humanised storage unit. The cost of storage is based on the daily peak of the number of units (or part thereof) used */\n unit_size: string;\n /** The peak number of storage units used today */\n units_used: number;\n};\n\nexport type ProductDmStorageDetailCoins = {\n /** The coin cost of a 'unit' of storage or part thereof. The unit size is defined in the storage section of the response */\n unit_cost: number;\n /** The number of coins currently committed for the current day. This is added to the accumulated coins at the start of each day */\n used: number;\n};\n\nexport interface ProductDmStorageDetail {\n coins: ProductDmStorageDetailCoins;\n size: ProductDmStorageDetailSize;\n}\n\nexport interface ProductDmProjectTier {\n claim?: ProductClaimDetail;\n /** True if the product can be (needs to be) claimed. */\n claimable: boolean;\n coins: ProductCoinsDetail;\n instance: ProductInstanceDetail;\n organisation: OrganisationAllDetail;\n product: ProductDetail;\n storage: ProductDmStorageDetail;\n unit: UnitAllDetail;\n}\n\nexport interface ProductDmStorage {\n /** True if the product can be (needs to be) claimed. */\n claimable: boolean;\n coins: ProductCoinsDetail;\n organisation: OrganisationAllDetail;\n product: ProductDetail;\n storage: ProductDmStorageDetail;\n unit: UnitAllDetail;\n}\n\nexport interface ChargeAdditionalData { [key: string]: any }\n\nexport interface StorageChargeItem {\n additional_data?: ChargeAdditionalData;\n /** The date when the charges concluded */\n closed?: string;\n /** The coin-cost of the storage */\n coins: string;\n /** The date and time of the processing charge */\n date: string;\n item_number: number;\n}\n\nexport interface StorageCharges {\n items: StorageChargeItem[];\n num_items: number;\n}\n\nexport interface ProcessingChargeItem {\n additional_data?: ChargeAdditionalData;\n /** The coin-cost of the storage */\n coins: string;\n /** The charge record number */\n id: number;\n name?: string;\n /** The most recent sequence number for this charge */\n sqn: number;\n /** The date and time of the processing charge */\n timestamp: string;\n username: string;\n}\n\nexport type ProcessingChargesMerchantKind = typeof ProcessingChargesMerchantKind[keyof typeof ProcessingChargesMerchantKind];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const ProcessingChargesMerchantKind = {\n DATA_MANAGER: 'DATA_MANAGER',\n} as const;\n\nexport interface ProcessingCharges {\n charge: ProcessingChargeItem;\n /** The date when the process stopped */\n closed?: string;\n /** True if no further change to the charges can occur. Typically True after the charge has been closed for a pre-configured period of time. */\n final: boolean;\n merchant_api_hostname: string;\n merchant_kind: ProcessingChargesMerchantKind;\n merchant_name: string;\n /** True if charges were received after the charge record was finalised */\n post_final_charges?: boolean;\n}\n\nexport type AssetDetailScope = typeof AssetDetailScope[keyof typeof AssetDetailScope];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const AssetDetailScope = {\n USER: 'USER',\n PRODUCT: 'PRODUCT',\n UNIT: 'UNIT',\n ORGANISATION: 'ORGANISATION',\n GLOBAL: 'GLOBAL',\n} as const;\n\nexport interface AssetDetail {\n content: string;\n content_modified?: string;\n created: string;\n creator: string;\n description?: string;\n disabled: boolean;\n id: string;\n merchants: MerchantDetail[];\n name: string;\n scope: AssetDetailScope;\n scope_id: string;\n secret: boolean;\n}\n\nexport type UserAccountGetResponse = UserAccountDetail;\n\nexport interface UnitsGetResponse {\n /** A list of Units\n */\n units: OrganisationUnitsGetResponse[];\n}\n\nexport type UnitGetResponse = UnitAllDetail;\n\nexport interface UnitProductPostResponse {\n /** The Product's unique ID */\n id: string;\n}\n\n/**\n * The type of charge\n */\nexport type ChargeSummaryType = typeof ChargeSummaryType[keyof typeof ChargeSummaryType];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const ChargeSummaryType = {\n PROCESSING: 'PROCESSING',\n STORAGE: 'STORAGE',\n} as const;\n\nexport interface ChargeSummary {\n /** The cost, in coins of the charge */\n coins: string;\n /** The type of charge */\n type: ChargeSummaryType;\n}\n\nexport interface UnitProductChargeSummary {\n charges: ChargeSummary[];\n product_id: string;\n product_type: string;\n}\n\nexport interface UnitChargeSummary {\n charges: ChargeSummary[];\n}\n\nexport interface UnitChargesGetResponse {\n billing_day: number;\n /** Whether the user making the API call is a member of the Unit */\n caller_is_member: boolean;\n coins: string;\n count: number;\n created: string;\n /** The start of the charge period */\n from: string;\n name?: string;\n /** The Unit's owner (a username) */\n owner_id: string;\n /** True if the Unit is private */\n private: boolean;\n products: UnitProductChargeSummary[];\n summary: UnitChargeSummary;\n unit_id: string;\n /** The date where of first day after the charge period */\n until: string;\n}\n\n/**\n * The Unit's Product\n */\nexport type ProductUnitGetResponseProduct = ProductDmStorage | ProductDmProjectTier;\n\nexport interface ProductUnitGetResponse {\n /** The Unit's Product */\n product: ProductUnitGetResponseProduct;\n}\n\nexport interface ProductsGetTypesResponse {\n /** The number of Product Types */\n count: number;\n /** All the Product Types you have access to */\n product_types: ProductType[];\n}\n\nexport type ProductsGetDefaultStorageCostDefaultStorageCost = {\n cost: string;\n description: string;\n units: string;\n};\n\nexport interface ProductsGetDefaultStorageCost {\n default_storage_cost: ProductsGetDefaultStorageCostDefaultStorageCost;\n}\n\nexport type ProductsGetResponseProductsItem = ProductDmStorage | ProductDmProjectTier;\n\nexport interface ProductsGetResponse {\n count: number;\n /** All the Products you have access to */\n products: ProductsGetResponseProductsItem[];\n}\n\nexport type ProductChargesGetResponseProductType = typeof ProductChargesGetResponseProductType[keyof typeof ProductChargesGetResponseProductType];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const ProductChargesGetResponseProductType = {\n DATA_MANAGER_PROJECT_TIER_SUBSCRIPTION: 'DATA_MANAGER_PROJECT_TIER_SUBSCRIPTION',\n DATA_MANAGER_STORAGE_SUBSCRIPTION: 'DATA_MANAGER_STORAGE_SUBSCRIPTION',\n} as const;\n\nexport interface ProductChargesGetResponse {\n billing_day: number;\n claim?: ProductClaimDetail;\n /** True if the product can be (needs to be) claimed. */\n claimable: boolean;\n /** The total number of coins consumed by this product for the invoice period */\n coins: string;\n count: number;\n /** The start of the charge period */\n from: string;\n processing_charges: ProcessingCharges[];\n product_id: string;\n product_type: ProductChargesGetResponseProductType;\n storage_charges: StorageCharges;\n /** The date where of first day after the charge period */\n until: string;\n}\n\nexport type OrganisationGetResponse = OrganisationAllDetail;\n\nexport interface OrganisationsGetResponse {\n count: number;\n /** A list of Organisations */\n organisations: OrganisationAllDetail[];\n}\n\nexport interface OrganisationUnitChargeSummary {\n billing_day: number;\n /** The start of the charge period */\n from: string;\n name: string;\n summary: ChargeSummary[];\n unit_id: string;\n /** The date where of first day after the charge period */\n until: string;\n}\n\nexport interface OrganisationChargesGetResponse {\n coins: string;\n name: string;\n organisation_id: string;\n summary: ChargeSummary[];\n unit_charges: OrganisationUnitChargeSummary[];\n}\n\nexport interface OrganisationUnitsGetResponse {\n count?: number;\n organisation: OrganisationAllDetail;\n /** A list of Units\n */\n units: UnitAllDetail[];\n}\n\nexport interface OrganisationChargeSummary {\n name: string;\n organisation_id: string;\n summary: ChargeSummary[];\n}\n\nexport interface PersonalUnitPutResponse {\n /** The unit's unique ID */\n id: string;\n /** The unit's Organisation. Used to identify the Default organisation */\n organisation_id: string;\n}\n\nexport interface OrganisationUnitPostResponse {\n /** The unit's unique ID */\n id: string;\n}\n\n/**\n * The Organisation's default product privacy setting\n */\nexport type OrganisationGetDefaultResponseDefaultProductPrivacy = typeof OrganisationGetDefaultResponseDefaultProductPrivacy[keyof typeof OrganisationGetDefaultResponseDefaultProductPrivacy];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const OrganisationGetDefaultResponseDefaultProductPrivacy = {\n ALWAYS_PUBLIC: 'ALWAYS_PUBLIC',\n ALWAYS_PRIVATE: 'ALWAYS_PRIVATE',\n DEFAULT_PUBLIC: 'DEFAULT_PUBLIC',\n DEFAULT_PRIVATE: 'DEFAULT_PRIVATE',\n} as const;\n\nexport interface OrganisationGetDefaultResponse {\n /** Whether the user making the API call is a member of the Default Organisation. Only admin users are members of the Default organisation */\n caller_is_member?: boolean;\n created?: string;\n /** The Organisation's default product privacy setting */\n default_product_privacy?: OrganisationGetDefaultResponseDefaultProductPrivacy;\n /** The Default Organisation ID\n */\n id?: string;\n /** The Default Organisation Name\n */\n name?: string;\n /** True if the Organisation is private. The Default organisation is always public, although it does not contain a membership (unless you're admin) and only houses Personal Units\n */\n private?: boolean;\n}\n\nexport interface UsersGetResponse {\n count: number;\n organisation?: OrganisationDetail;\n unit?: UnitDetail;\n /** The list of Organisation Users\n */\n users: UserDetail[];\n}\n\nexport interface OrganisationPostResponse {\n /** The Organisation's unique ID */\n id: string;\n}\n\nexport interface StateGetVersionResponse {\n /** The Account Server version. This is guaranteed to be a valid semantic version for official (tagged) images. The version value format for unofficial images is a string but otherwise undefined\n */\n version: string;\n}\n\nexport interface EventStreamGetPostResponse {\n /** The EventStream ID */\n id: number;\n /** The EventStream read token, required to read from the stream */\n read_token: string;\n}\n\nexport interface ChargesGetResponse {\n coins: string;\n count: number;\n organisation_charges: OrganisationChargeSummary[];\n summary: ChargeSummary[];\n}\n\nexport interface AssetPostResponse {\n /** The Asset ID\n */\n id: string;\n}\n\nexport interface AssetGetResponse {\n /** A list of Assets\n */\n assets: AssetDetail[];\n /** The number of Assets returned\n */\n count: number;\n}\n\nexport type AssetGetByIdResponse = AssetDetail;\n\nexport interface AsError {\n /** Brief error text that can be presented to the user */\n error: string;\n}\n\n"],"mappings":";;;;;;;;AAiKO,IAAM,8BAA8B;AAAA,EACzC,wCAAwC;AAAA,EACxC,mCAAmC;AACrC;AASO,IAAM,iCAAiC;AAAA,EAC5C,YAAY;AAAA,EACZ,QAAQ;AAAA,EACR,QAAQ;AAAA,EACR,MAAM;AACR;AA0BO,IAAM,yCAAyC;AAAA,EACpD,eAAe;AAAA,EACf,gBAAgB;AAAA,EAChB,gBAAgB;AAAA,EAChB,iBAAiB;AACnB;AAoBO,IAAM,iDAAiD;AAAA,EAC5D,eAAe;AAAA,EACf,gBAAgB;AAAA,EAChB,gBAAgB;AAAA,EAChB,iBAAiB;AACnB;AAkBO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EO,IAAM,uCAAuC;AAAA,EAClD,wCAAwC;AAAA,EACxC,mCAAmC;AACrC;AAgFO,IAAM,sDAAsD;AAAA,EACjE,eAAe;AAAA,EACf,gBAAgB;AAAA,EAChB,gBAAgB;AAAA,EAChB,iBAAiB;AACnB;","names":[]}
1
+ {"version":3,"sources":["../src/account-server-api.schemas.ts"],"sourcesContent":["/**\n * Generated by orval v6.25.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: 2.4\n */\nexport type DetachAssetParams = {\n/**\n * A Merchant Identity\n */\nm_id?: QMIdParameter;\n};\n\nexport type AttachAssetParams = {\n/**\n * A Merchant Identity\n */\nm_id?: QMIdParameter;\n};\n\n/**\n * A date where assets prior to this will be returned. This can be a date-time string but it is interpreted as a date, i.e. `2020-01-01T00:00:00Z` is interpreted as `2020-01-01`. Any asset that occurs prior this date will be returned. UTC is assumed if no timezone is provided\n */\nexport type QUntilParameter = string;\n\n/**\n * A date from which to retrieve assets. This can be a date-time string but it is interpreted as a date, i.e. `2020-01-01T00:00:00Z` is interpreted as `2020-01-01`. Any asset that occurs on ar after this date will be returned. UTC is assumed if no timezone is provided\n */\nexport type QFromParameter = string;\n\nexport type GetUnitChargesParams = {\n/**\n * A date from which to retrieve assets. This can be a date-time string but it is interpreted as a date, i.e. `2020-01-01T00:00:00Z` is interpreted as `2020-01-01`. Any asset that occurs on ar after this date will be returned. UTC is assumed if no timezone is provided\n */\nfrom?: QFromParameter;\n/**\n * A date where assets prior to this will be returned. This can be a date-time string but it is interpreted as a date, i.e. `2020-01-01T00:00:00Z` is interpreted as `2020-01-01`. Any asset that occurs prior this date will be returned. UTC is assumed if no timezone is provided\n */\nuntil?: QUntilParameter;\n/**\n * A charge Prior Billing Period, 0 implies \"current\" and -23 is for the period 23 months ago.\n */\npbp?: QPbpParameter;\n};\n\nexport type GetProductChargesParams = {\n/**\n * A date from which to retrieve assets. This can be a date-time string but it is interpreted as a date, i.e. `2020-01-01T00:00:00Z` is interpreted as `2020-01-01`. Any asset that occurs on ar after this date will be returned. UTC is assumed if no timezone is provided\n */\nfrom?: QFromParameter;\n/**\n * A date where assets prior to this will be returned. This can be a date-time string but it is interpreted as a date, i.e. `2020-01-01T00:00:00Z` is interpreted as `2020-01-01`. Any asset that occurs prior this date will be returned. UTC is assumed if no timezone is provided\n */\nuntil?: QUntilParameter;\n/**\n * A charge Prior Billing Period, 0 implies \"current\" and -23 is for the period 23 months ago.\n */\npbp?: QPbpParameter;\n};\n\nexport type GetOrganisationChargesParams = {\n/**\n * A date from which to retrieve assets. This can be a date-time string but it is interpreted as a date, i.e. `2020-01-01T00:00:00Z` is interpreted as `2020-01-01`. Any asset that occurs on ar after this date will be returned. UTC is assumed if no timezone is provided\n */\nfrom?: QFromParameter;\n/**\n * A date where assets prior to this will be returned. This can be a date-time string but it is interpreted as a date, i.e. `2020-01-01T00:00:00Z` is interpreted as `2020-01-01`. Any asset that occurs prior this date will be returned. UTC is assumed if no timezone is provided\n */\nuntil?: QUntilParameter;\n/**\n * A charge Prior Billing Period, 0 implies \"current\" and -23 is for the period 23 months ago.\n */\npbp?: QPbpParameter;\n};\n\nexport type GetChargesParams = {\n/**\n * A date from which to retrieve assets. This can be a date-time string but it is interpreted as a date, i.e. `2020-01-01T00:00:00Z` is interpreted as `2020-01-01`. Any asset that occurs on ar after this date will be returned. UTC is assumed if no timezone is provided\n */\nfrom?: QFromParameter;\n/**\n * A date where assets prior to this will be returned. This can be a date-time string but it is interpreted as a date, i.e. `2020-01-01T00:00:00Z` is interpreted as `2020-01-01`. Any asset that occurs prior this date will be returned. UTC is assumed if no timezone is provided\n */\nuntil?: QUntilParameter;\n/**\n * A charge Prior Billing Period, 0 implies \"current\" and -23 is for the period 23 months ago.\n */\npbp?: QPbpParameter;\n};\n\n/**\n * A User Identity\n */\nexport type QUserIdParameter = string;\n\n/**\n * A Product Identity\n */\nexport type QProductIdParameter = string;\n\n/**\n * A Unit Identity\n */\nexport type QUnitIdParameter = string;\n\nexport type GetAssetParams = {\n/**\n * A User Identity\n */\nuser_id?: QUserIdParameter;\n/**\n * A Product Identity\n */\nproduct_id?: QProductIdParameter;\n/**\n * A Unit Identity\n */\nunit_id?: QUnitIdParameter;\n/**\n * An Organisation Identity\n */\norg_id?: QOrgIdParameter;\n};\n\n/**\n * A Merchant Identity\n */\nexport type QMIdParameter = number;\n\n/**\n * An Organisation Identity\n */\nexport type QOrgIdParameter = string;\n\n/**\n * A charge Prior Billing Period, 0 implies \"current\" and -23 is for the period 23 months ago.\n */\nexport type QPbpParameter = number;\n\nexport type ProductPatchBodyBody = {\n /** The Product's built-in coin allowance. Product allowances cannot be reduced */\n allowance?: number;\n /** The Product's built-in coin limit. If set it must not be less than the allowance. If not set the allowance is used. The existing product limit cannot be reduced */\n limit?: number;\n /** The name you want to give the Product */\n name?: string;\n};\n\n/**\n * The Type of Product. Storage subscriptions require an **Allowance** to be defined and the **Flavour** must not be provided.\n\nProject Tier subscriptions have built-in allowances and Limits so you must not provide values for these for these products\n */\nexport type UnitProductPostBodyBodyType = typeof UnitProductPostBodyBodyType[keyof typeof UnitProductPostBodyBodyType];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const UnitProductPostBodyBodyType = {\n DATA_MANAGER_PROJECT_TIER_SUBSCRIPTION: 'DATA_MANAGER_PROJECT_TIER_SUBSCRIPTION',\n DATA_MANAGER_STORAGE_SUBSCRIPTION: 'DATA_MANAGER_STORAGE_SUBSCRIPTION',\n} as const;\n\n/**\n * The Flavour of the Product. Used only for Project Tier Products. Do not set this for Storage products\n */\nexport type UnitProductPostBodyBodyFlavour = typeof UnitProductPostBodyBodyFlavour[keyof typeof UnitProductPostBodyBodyFlavour];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const UnitProductPostBodyBodyFlavour = {\n EVALUATION: 'EVALUATION',\n BRONZE: 'BRONZE',\n SILVER: 'SILVER',\n GOLD: 'GOLD',\n} as const;\n\nexport type UnitProductPostBodyBody = {\n /** The Product's coin allowance. You must provide this for Storage products but you must not provide a value for Project Tier Products */\n allowance?: number;\n /** The Flavour of the Product. Used only for Project Tier Products. Do not set this for Storage products */\n flavour?: UnitProductPostBodyBodyFlavour;\n /** The Product's built-in coin limit. If set it must not be less than the allowance. If not set the allowance is used. You can provide this for Storage products but you must not provide a value for Project Tier Products */\n limit?: number;\n /** The name you want to give the Product */\n name: string;\n /** The Type of Product. Storage subscriptions require an **Allowance** to be defined and the **Flavour** must not be provided.\n\nProject Tier subscriptions have built-in allowances and Limits so you must not provide values for these for these products */\n type: UnitProductPostBodyBodyType;\n};\n\n/**\n * The new default **Product** privacy applied to all products that belong to this Unit. Privacy is also controlled at the **Organisation** level. As an example, the Unit can declare its Products to be `DEFAULT_PRIVATE`, but the Organisation can declare its value to be `DEFAULT_PUBLIC`.\n\nWhether the privacy can be honoured will depend on the organisation's value\n */\nexport type UnitPatchBodyBodyDefaultProductPrivacy = typeof UnitPatchBodyBodyDefaultProductPrivacy[keyof typeof UnitPatchBodyBodyDefaultProductPrivacy];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const UnitPatchBodyBodyDefaultProductPrivacy = {\n ALWAYS_PUBLIC: 'ALWAYS_PUBLIC',\n ALWAYS_PRIVATE: 'ALWAYS_PRIVATE',\n DEFAULT_PUBLIC: 'DEFAULT_PUBLIC',\n DEFAULT_PRIVATE: 'DEFAULT_PRIVATE',\n} as const;\n\nexport type UnitPatchBodyBody = {\n /** The new default **Product** privacy applied to all products that belong to this Unit. Privacy is also controlled at the **Organisation** level. As an example, the Unit can declare its Products to be `DEFAULT_PRIVATE`, but the Organisation can declare its value to be `DEFAULT_PUBLIC`.\n\nWhether the privacy can be honoured will depend on the organisation's value */\n default_product_privacy?: UnitPatchBodyBodyDefaultProductPrivacy;\n /** The new name for the Unit */\n name?: string;\n};\n\n/**\n * The new default **Product** privacy applied to all products that belong to this Organisation. Privacy is also controlled at the **Unit** level. As an example the Organisation level privacy can be `DEFAULT_PRIVATE`, but the unit can declare its Products to be `ALWAYS_PRIVATE`.\n\nWhether the privacy can be honoured will depend on the value in any of the organisation's existing units\n */\nexport type OrganisationPatchBodyBodyDefaultProductPrivacy = typeof OrganisationPatchBodyBodyDefaultProductPrivacy[keyof typeof OrganisationPatchBodyBodyDefaultProductPrivacy];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const OrganisationPatchBodyBodyDefaultProductPrivacy = {\n ALWAYS_PUBLIC: 'ALWAYS_PUBLIC',\n ALWAYS_PRIVATE: 'ALWAYS_PRIVATE',\n DEFAULT_PUBLIC: 'DEFAULT_PUBLIC',\n DEFAULT_PRIVATE: 'DEFAULT_PRIVATE',\n} as const;\n\nexport type OrganisationPatchBodyBody = {\n /** The new default **Product** privacy applied to all products that belong to this Organisation. Privacy is also controlled at the **Unit** level. As an example the Organisation level privacy can be `DEFAULT_PRIVATE`, but the unit can declare its Products to be `ALWAYS_PRIVATE`.\n\nWhether the privacy can be honoured will depend on the value in any of the organisation's existing units */\n default_product_privacy?: OrganisationPatchBodyBodyDefaultProductPrivacy;\n /** The new name for the Organisational */\n name?: string;\n};\n\n/**\n * The default product privacy setting for products in the unit. Whether the privacy can be honoured will depend on the organisation's value\n */\nexport type OrganisationUnitPostBodyBodyDefaultProductPrivacy = typeof OrganisationUnitPostBodyBodyDefaultProductPrivacy[keyof typeof OrganisationUnitPostBodyBodyDefaultProductPrivacy];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const OrganisationUnitPostBodyBodyDefaultProductPrivacy = {\n ALWAYS_PUBLIC: 'ALWAYS_PUBLIC',\n ALWAYS_PRIVATE: 'ALWAYS_PRIVATE',\n DEFAULT_PUBLIC: 'DEFAULT_PUBLIC',\n DEFAULT_PRIVATE: 'DEFAULT_PRIVATE',\n} as const;\n\nexport type OrganisationUnitPostBodyBody = {\n /** The day you would like to be billed for the Unit's Products (a value from 1 and 28) */\n billing_day: number;\n /** The default product privacy setting for products in the unit. Whether the privacy can be honoured will depend on the organisation's value */\n default_product_privacy?: OrganisationUnitPostBodyBodyDefaultProductPrivacy;\n /** The name of the unit */\n name: string;\n};\n\nexport type PersonalUnitPutBodyBody = {\n /** The day you would like to be billed for the Unit's Products (a value from 1 and 28) */\n billing_day: number;\n};\n\n/**\n * The default product privacy setting for the Organisation\n */\nexport type OrganisationPostBodyBodyDefaultProductPrivacy = typeof OrganisationPostBodyBodyDefaultProductPrivacy[keyof typeof OrganisationPostBodyBodyDefaultProductPrivacy];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const OrganisationPostBodyBodyDefaultProductPrivacy = {\n ALWAYS_PUBLIC: 'ALWAYS_PUBLIC',\n ALWAYS_PRIVATE: 'ALWAYS_PRIVATE',\n DEFAULT_PUBLIC: 'DEFAULT_PUBLIC',\n DEFAULT_PRIVATE: 'DEFAULT_PRIVATE',\n} as const;\n\nexport type OrganisationPostBodyBody = {\n /** The default product privacy setting for the Organisation */\n default_product_privacy?: OrganisationPostBodyBodyDefaultProductPrivacy;\n /** The name of the organisation */\n name: string;\n /** The name of the organisation owner. A user ID */\n owner: string;\n};\n\nexport type AssetPostBodyBodyScope = typeof AssetPostBodyBodyScope[keyof typeof AssetPostBodyBodyScope];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const AssetPostBodyBodyScope = {\n USER: 'USER',\n PRODUCT: 'PRODUCT',\n UNIT: 'UNIT',\n ORGANISATION: 'ORGANISATION',\n GLOBAL: 'GLOBAL',\n} as const;\n\nexport type AssetPostBodyBody = {\n /** A file containing the content for the asset. You must provide a value here or in content_string */\n content_file?: Blob;\n /** The textual content of the asset. You must provide a value here or in content_file */\n content_string?: string;\n /** An optional description for the Asset */\n description?: string;\n /** The name of the asset. This must be unique within its scope. For example, only one asset can be called \"asset-1\" within a given Unit. Asset names must be valid RFC 1123 Label Names */\n name: string;\n scope: AssetPostBodyBodyScope;\n /** The unique identity based on the Scope of the asset. For example, this will be the Unit ID if it's a UNIT. A scope_id is required if the scope is USER as it will be automatically set to your username. Global assets do not have a scope. */\n scope_id?: string;\n /** Is this a secret asset? */\n secret: boolean;\n};\n\nexport type AssetPatchBodyBody = {\n /** A file containing the content for the asset. You must provide a value here or in content_string */\n content_file?: Blob;\n /** The textual content of the asset. You must provide a value here or in content_file */\n content_string?: string;\n /** An optional description for the Asset */\n description?: string;\n};\n\nexport interface UserDetail {\n /** The user identity (username) */\n id: string;\n}\n\nexport interface UserAccountDetail {\n /** The roles assigned to the user recognised by the Account Server */\n account_server_roles: string[];\n /** Whether the caller has admin privilege */\n caller_has_admin_privilege: boolean;\n user: UserDetail;\n}\n\n/**\n * The Unit's default product privacy setting\n */\nexport type UnitDetailDefaultProductPrivacy = typeof UnitDetailDefaultProductPrivacy[keyof typeof UnitDetailDefaultProductPrivacy];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const UnitDetailDefaultProductPrivacy = {\n ALWAYS_PUBLIC: 'ALWAYS_PUBLIC',\n ALWAYS_PRIVATE: 'ALWAYS_PRIVATE',\n DEFAULT_PUBLIC: 'DEFAULT_PUBLIC',\n DEFAULT_PRIVATE: 'DEFAULT_PRIVATE',\n} as const;\n\nexport interface UnitDetail {\n /** The Unit's billing day */\n billing_day: number;\n /** Whether the user making the API call is a member of the Unit */\n caller_is_member: boolean;\n created: string;\n /** The Unit's default product privacy setting */\n default_product_privacy: UnitDetailDefaultProductPrivacy;\n /** The Unit's unique identity */\n id: string;\n /** The Unit's name */\n name: string;\n /** The Unit's owner (a username) */\n owner_id: string;\n /** True if the Unit is private */\n private: boolean;\n}\n\n/**\n * The Unit's default product privacy setting\n */\nexport type UnitAllDetailDefaultProductPrivacy = typeof UnitAllDetailDefaultProductPrivacy[keyof typeof UnitAllDetailDefaultProductPrivacy];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const UnitAllDetailDefaultProductPrivacy = {\n ALWAYS_PUBLIC: 'ALWAYS_PUBLIC',\n ALWAYS_PRIVATE: 'ALWAYS_PRIVATE',\n DEFAULT_PUBLIC: 'DEFAULT_PUBLIC',\n DEFAULT_PRIVATE: 'DEFAULT_PRIVATE',\n} as const;\n\nexport interface UnitAllDetail {\n /** The Unit's billing day */\n billing_day: number;\n /** Whether the user making the API call is a member of the Unit */\n caller_is_member: boolean;\n created: string;\n /** The Unit's default product privacy setting */\n default_product_privacy: UnitAllDetailDefaultProductPrivacy;\n /** The Unit's unique identity */\n id: string;\n /** The Unit's name */\n name: string;\n /** The Unit's owner (a username) */\n owner_id: string;\n /** True if the Unit is private */\n private: boolean;\n /** A list of users that are members of the Unit */\n users: UserDetail[];\n}\n\n/**\n * The kind of Service\n */\nexport type MerchantDetailKind = typeof MerchantDetailKind[keyof typeof MerchantDetailKind];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const MerchantDetailKind = {\n DATA_MANAGER: 'DATA_MANAGER',\n} as const;\n\nexport interface MerchantDetail {\n /** The hostname used by the Service */\n api_hostname: string;\n created: string;\n /** The unique ID of the Service */\n id: number;\n /** The kind of Service */\n kind: MerchantDetailKind;\n /** The name assigned to the Service */\n name: string;\n}\n\nexport type MerchantGetResponse = MerchantDetail;\n\nexport interface MerchantsGetResponse {\n count?: number;\n /** The list of known Merchants\n */\n merchants: MerchantDetail[];\n}\n\n/**\n * The Organisation's default product privacy setting\n */\nexport type OrganisationDetailDefaultProductPrivacy = typeof OrganisationDetailDefaultProductPrivacy[keyof typeof OrganisationDetailDefaultProductPrivacy];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const OrganisationDetailDefaultProductPrivacy = {\n ALWAYS_PUBLIC: 'ALWAYS_PUBLIC',\n ALWAYS_PRIVATE: 'ALWAYS_PRIVATE',\n DEFAULT_PUBLIC: 'DEFAULT_PUBLIC',\n DEFAULT_PRIVATE: 'DEFAULT_PRIVATE',\n} as const;\n\nexport interface OrganisationDetail {\n /** Whether the user making the API call is a member of the Unit */\n caller_is_member: boolean;\n created: string;\n /** The Organisation's default product privacy setting */\n default_product_privacy: OrganisationDetailDefaultProductPrivacy;\n /** The Organisation's unique ID */\n id: string;\n /** The Organisation's name */\n name: string;\n /** The username of the Organisation's owner. Not all Organisations have an owner. The Default Organisation has no owner. */\n owner_id?: string;\n /** True if the Unit is private */\n private: boolean;\n}\n\n/**\n * The Organisation's default product privacy setting\n */\nexport type OrganisationAllDetailDefaultProductPrivacy = typeof OrganisationAllDetailDefaultProductPrivacy[keyof typeof OrganisationAllDetailDefaultProductPrivacy];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const OrganisationAllDetailDefaultProductPrivacy = {\n ALWAYS_PUBLIC: 'ALWAYS_PUBLIC',\n ALWAYS_PRIVATE: 'ALWAYS_PRIVATE',\n DEFAULT_PUBLIC: 'DEFAULT_PUBLIC',\n DEFAULT_PRIVATE: 'DEFAULT_PRIVATE',\n} as const;\n\nexport interface OrganisationAllDetail {\n /** Whether the user making the API call is a member of the Unit */\n caller_is_member: boolean;\n created: string;\n /** The Organisation's default product privacy setting */\n default_product_privacy: OrganisationAllDetailDefaultProductPrivacy;\n /** The Organisation's unique ID */\n id: string;\n /** The Organisation's name */\n name: string;\n /** The username of the Organisation's owner. Not all Organisations have an owner. The Default Organisation has no owner. */\n owner_id?: string;\n /** True if the Unit is private */\n private: boolean;\n /** A list of users that are members of the Organisation */\n users: UserDetail[];\n}\n\n/**\n * The kind of service that can use the Product\n */\nexport type ProductTypeServiceKind = typeof ProductTypeServiceKind[keyof typeof ProductTypeServiceKind];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const ProductTypeServiceKind = {\n DATA_MANAGER: 'DATA_MANAGER',\n} as const;\n\nexport interface ProductType {\n /** A product flavour. Not all types have a flavour, those that do have a type-specific flavour string */\n flavour?: string;\n /** The kind of service that can use the Product */\n service_kind?: ProductTypeServiceKind;\n /** A product type, this is a unique string amongst all types known to the Account Server */\n type: string;\n}\n\nexport type ProductInstanceDetailCoins = {\n /** The number of coins used\n */\n used: number;\n};\n\nexport interface ProductInstanceDetail {\n coins: ProductInstanceDetailCoins;\n}\n\n/**\n * The Product Type\n\n */\nexport type ProductDetailType = typeof ProductDetailType[keyof typeof ProductDetailType];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const ProductDetailType = {\n DATA_MANAGER_PROJECT_TIER_SUBSCRIPTION: 'DATA_MANAGER_PROJECT_TIER_SUBSCRIPTION',\n DATA_MANAGER_STORAGE_SUBSCRIPTION: 'DATA_MANAGER_STORAGE_SUBSCRIPTION',\n} as const;\n\n/**\n * The Product Type flavour. Not all products have flavours\n\n */\nexport type ProductDetailFlavour = typeof ProductDetailFlavour[keyof typeof ProductDetailFlavour];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const ProductDetailFlavour = {\n EVALUATION: 'EVALUATION',\n BRONZE: 'BRONZE',\n SILVER: 'SILVER',\n GOLD: 'GOLD',\n} as const;\n\nexport interface ProductDetail {\n created: string;\n /** The Product Type flavour. Not all products have flavours\n */\n flavour?: ProductDetailFlavour;\n /** The Product ID\n */\n id: string;\n /** The name of the Product\n */\n name?: string;\n /** The Product Type\n */\n type: ProductDetailType;\n}\n\nexport interface ProductCoinsDetail {\n /** The billing allowance. When you exceed this during the current billing period the *cost multiplier* will increase */\n allowance: number;\n /** A multiplier applied to your coin usage within your allowance */\n allowance_multiplier: number;\n /** True if the product is operating at or beyond its coin limit. When it is authority to perform actions using the product are severely limited. */\n at_limit: boolean;\n /** The day of the month when the bill is due, and the end of the current billing period */\n billing_day: number;\n /** The predicted total billing period amount, if costs continue at the current burn rate until the end of the billing period. This is an estimate */\n billing_prediction: number;\n /** The predicted storage contribution to the billing period amount, if costs continue at the current burn rate until the end of the billing period. This is an estimate */\n billing_prediction_storage_contribution: number;\n /** The current burn rate, the approximate amount of coins you are currently consuming each day */\n current_burn_rate: number;\n /** The limit on your billing period spend. You can exceed the allowance but you cannot exceed the spend limit. Once reached the dependent may be restricted */\n limit: number;\n /** A multiplier that will be applied to coin used beyond your allowance */\n overspend_multiplier: number;\n /** The number of days remaining, in the current billing period */\n remaining_days: number;\n /** The total number of coins consumed (in this billing period), excluding the coins that have been consumed for the current day */\n used: number;\n}\n\nexport interface ProductClaimDetail {\n /** The service-specific ID that is using this Subscription\n */\n id: string;\n /** A name for the service-specific ID\n */\n name?: string;\n}\n\nexport type ProductDmStorageDetailSize = {\n /** The humanised size of the current storage used for the current day and used to calculate the 'burn rate' */\n current: string;\n /** The humanised size of the peak storage used for the current day. The value is reset at the start of each day */\n peak: string;\n /** The humanised storage unit. The cost of storage is based on the daily peak of the number of units (or part thereof) used */\n unit_size: string;\n /** The peak number of storage units used today */\n units_used: number;\n};\n\nexport type ProductDmStorageDetailCoins = {\n /** The coin cost of a 'unit' of storage or part thereof. The unit size is defined in the storage section of the response */\n unit_cost: number;\n /** The number of coins currently committed for the current day. This is added to the accumulated coins at the start of each day */\n used: number;\n};\n\nexport interface ProductDmStorageDetail {\n coins: ProductDmStorageDetailCoins;\n size: ProductDmStorageDetailSize;\n}\n\nexport interface ProductDmProjectTier {\n claim?: ProductClaimDetail;\n /** True if the product can be (needs to be) claimed. */\n claimable: boolean;\n coins: ProductCoinsDetail;\n instance: ProductInstanceDetail;\n organisation: OrganisationAllDetail;\n product: ProductDetail;\n storage: ProductDmStorageDetail;\n unit: UnitAllDetail;\n}\n\nexport interface ProductDmStorage {\n /** True if the product can be (needs to be) claimed. */\n claimable: boolean;\n coins: ProductCoinsDetail;\n organisation: OrganisationAllDetail;\n product: ProductDetail;\n storage: ProductDmStorageDetail;\n unit: UnitAllDetail;\n}\n\nexport interface ChargeAdditionalData { [key: string]: any }\n\nexport interface StorageChargeItem {\n additional_data?: ChargeAdditionalData;\n /** The date when the charges concluded */\n closed?: string;\n /** The coin-cost of the storage */\n coins: string;\n /** The date and time of the processing charge */\n date: string;\n item_number: number;\n}\n\nexport interface StorageCharges {\n items: StorageChargeItem[];\n num_items: number;\n}\n\nexport interface ProcessingChargeItem {\n additional_data?: ChargeAdditionalData;\n /** The coin-cost of the storage */\n coins: string;\n /** The charge record number */\n id: number;\n name?: string;\n /** The most recent sequence number for this charge */\n sqn: number;\n /** The date and time of the processing charge */\n timestamp: string;\n username: string;\n}\n\nexport type ProcessingChargesMerchantKind = typeof ProcessingChargesMerchantKind[keyof typeof ProcessingChargesMerchantKind];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const ProcessingChargesMerchantKind = {\n DATA_MANAGER: 'DATA_MANAGER',\n} as const;\n\nexport interface ProcessingCharges {\n charge: ProcessingChargeItem;\n /** The date when the process stopped */\n closed?: string;\n /** True if no further change to the charges can occur. Typically True after the charge has been closed for a pre-configured period of time. */\n final: boolean;\n merchant_api_hostname: string;\n merchant_kind: ProcessingChargesMerchantKind;\n merchant_name: string;\n /** True if charges were received after the charge record was finalised */\n post_final_charges?: boolean;\n}\n\nexport type AssetDetailScope = typeof AssetDetailScope[keyof typeof AssetDetailScope];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const AssetDetailScope = {\n USER: 'USER',\n PRODUCT: 'PRODUCT',\n UNIT: 'UNIT',\n ORGANISATION: 'ORGANISATION',\n GLOBAL: 'GLOBAL',\n} as const;\n\nexport interface AssetDetail {\n content: string;\n content_modified?: string;\n created: string;\n creator: string;\n description?: string;\n disabled: boolean;\n id: string;\n merchants: MerchantDetail[];\n name: string;\n scope: AssetDetailScope;\n scope_id: string;\n secret: boolean;\n}\n\nexport type UserAccountGetResponse = UserAccountDetail;\n\nexport interface UnitsGetResponse {\n /** A list of Units\n */\n units: OrganisationUnitsGetResponse[];\n}\n\nexport type UnitGetResponse = UnitAllDetail;\n\nexport interface UnitProductPostResponse {\n /** The Product's unique ID */\n id: string;\n}\n\n/**\n * The type of charge\n */\nexport type ChargeSummaryType = typeof ChargeSummaryType[keyof typeof ChargeSummaryType];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const ChargeSummaryType = {\n PROCESSING: 'PROCESSING',\n STORAGE: 'STORAGE',\n} as const;\n\nexport interface ChargeSummary {\n /** The cost, in coins of the charge */\n coins: string;\n /** The type of charge */\n type: ChargeSummaryType;\n}\n\nexport interface UnitProductChargeSummary {\n charges: ChargeSummary[];\n product_id: string;\n product_type: string;\n}\n\nexport interface UnitChargeSummary {\n charges: ChargeSummary[];\n}\n\nexport interface UnitChargesGetResponse {\n billing_day: number;\n /** Whether the user making the API call is a member of the Unit */\n caller_is_member: boolean;\n coins: string;\n count: number;\n created: string;\n /** The start of the charge period */\n from: string;\n name?: string;\n /** The Unit's owner (a username) */\n owner_id: string;\n /** True if the Unit is private */\n private: boolean;\n products: UnitProductChargeSummary[];\n summary: UnitChargeSummary;\n unit_id: string;\n /** The date where of first day after the charge period */\n until: string;\n}\n\n/**\n * The Unit's Product\n */\nexport type ProductUnitGetResponseProduct = ProductDmStorage | ProductDmProjectTier;\n\nexport interface ProductUnitGetResponse {\n /** The Unit's Product */\n product: ProductUnitGetResponseProduct;\n}\n\nexport interface ProductsGetTypesResponse {\n /** The number of Product Types */\n count: number;\n /** All the Product Types you have access to */\n product_types: ProductType[];\n}\n\nexport type ProductsGetDefaultStorageCostDefaultStorageCost = {\n cost: string;\n description: string;\n units: string;\n};\n\nexport interface ProductsGetDefaultStorageCost {\n default_storage_cost: ProductsGetDefaultStorageCostDefaultStorageCost;\n}\n\nexport type ProductsGetResponseProductsItem = ProductDmStorage | ProductDmProjectTier;\n\nexport interface ProductsGetResponse {\n count: number;\n /** All the Products you have access to */\n products: ProductsGetResponseProductsItem[];\n}\n\nexport type ProductChargesGetResponseProductType = typeof ProductChargesGetResponseProductType[keyof typeof ProductChargesGetResponseProductType];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const ProductChargesGetResponseProductType = {\n DATA_MANAGER_PROJECT_TIER_SUBSCRIPTION: 'DATA_MANAGER_PROJECT_TIER_SUBSCRIPTION',\n DATA_MANAGER_STORAGE_SUBSCRIPTION: 'DATA_MANAGER_STORAGE_SUBSCRIPTION',\n} as const;\n\nexport interface ProductChargesGetResponse {\n billing_day: number;\n claim?: ProductClaimDetail;\n /** True if the product can be (needs to be) claimed. */\n claimable: boolean;\n /** The total number of coins consumed by this product for the invoice period */\n coins: string;\n count: number;\n /** The start of the charge period */\n from: string;\n processing_charges: ProcessingCharges[];\n product_id: string;\n product_type: ProductChargesGetResponseProductType;\n storage_charges: StorageCharges;\n /** The date where of first day after the charge period */\n until: string;\n}\n\nexport type OrganisationGetResponse = OrganisationAllDetail;\n\nexport interface OrganisationsGetResponse {\n count: number;\n /** A list of Organisations */\n organisations: OrganisationAllDetail[];\n}\n\nexport interface OrganisationUnitChargeSummary {\n billing_day: number;\n /** The start of the charge period */\n from: string;\n name: string;\n summary: ChargeSummary[];\n unit_id: string;\n /** The date where of first day after the charge period */\n until: string;\n}\n\nexport interface OrganisationChargesGetResponse {\n coins: string;\n name: string;\n organisation_id: string;\n summary: ChargeSummary[];\n unit_charges: OrganisationUnitChargeSummary[];\n}\n\nexport interface OrganisationUnitsGetResponse {\n count?: number;\n organisation: OrganisationAllDetail;\n /** A list of Units\n */\n units: UnitAllDetail[];\n}\n\nexport interface OrganisationChargeSummary {\n name: string;\n organisation_id: string;\n summary: ChargeSummary[];\n}\n\nexport interface PersonalUnitPutResponse {\n /** The unit's unique ID */\n id: string;\n /** The unit's Organisation. Used to identify the Default organisation */\n organisation_id: string;\n}\n\nexport interface OrganisationUnitPostResponse {\n /** The unit's unique ID */\n id: string;\n}\n\n/**\n * The Organisation's default product privacy setting\n */\nexport type OrganisationGetDefaultResponseDefaultProductPrivacy = typeof OrganisationGetDefaultResponseDefaultProductPrivacy[keyof typeof OrganisationGetDefaultResponseDefaultProductPrivacy];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const OrganisationGetDefaultResponseDefaultProductPrivacy = {\n ALWAYS_PUBLIC: 'ALWAYS_PUBLIC',\n ALWAYS_PRIVATE: 'ALWAYS_PRIVATE',\n DEFAULT_PUBLIC: 'DEFAULT_PUBLIC',\n DEFAULT_PRIVATE: 'DEFAULT_PRIVATE',\n} as const;\n\nexport interface OrganisationGetDefaultResponse {\n /** Whether the user making the API call is a member of the Default Organisation. Only admin users are members of the Default organisation */\n caller_is_member?: boolean;\n created?: string;\n /** The Organisation's default product privacy setting */\n default_product_privacy?: OrganisationGetDefaultResponseDefaultProductPrivacy;\n /** The Default Organisation ID\n */\n id?: string;\n /** The Default Organisation Name\n */\n name?: string;\n /** True if the Organisation is private. The Default organisation is always public, although it does not contain a membership (unless you're admin) and only houses Personal Units\n */\n private?: boolean;\n}\n\nexport interface UsersGetResponse {\n count: number;\n organisation?: OrganisationDetail;\n unit?: UnitDetail;\n /** The list of Organisation Users\n */\n users: UserDetail[];\n}\n\nexport interface OrganisationPostResponse {\n /** The Organisation's unique ID */\n id: string;\n}\n\nexport interface StateGetVersionResponse {\n /** The Account Server version. This is guaranteed to be a valid semantic version for official (tagged) images. The version value format for unofficial images is a string but otherwise undefined\n */\n version: string;\n}\n\nexport interface EventStreamGetPostResponse {\n /** The EventStream ID */\n id: number;\n /** The EventStream read token, required to read from the stream */\n read_token: string;\n}\n\nexport interface ChargesGetResponse {\n coins: string;\n count: number;\n organisation_charges: OrganisationChargeSummary[];\n summary: ChargeSummary[];\n}\n\nexport interface AssetPostResponse {\n /** The Asset ID\n */\n id: string;\n}\n\nexport interface AssetGetResponse {\n /** A list of Assets\n */\n assets: AssetDetail[];\n /** The number of Assets returned\n */\n count: number;\n}\n\nexport type AssetGetByIdResponse = AssetDetail;\n\nexport interface AsError {\n /** Brief error text that can be presented to the user */\n error: string;\n}\n\n"],"mappings":";;;;;;;;AAiKO,IAAM,8BAA8B;AAAA,EACzC,wCAAwC;AAAA,EACxC,mCAAmC;AACrC;AASO,IAAM,iCAAiC;AAAA,EAC5C,YAAY;AAAA,EACZ,QAAQ;AAAA,EACR,QAAQ;AAAA,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;AACR;AAqIO,IAAM,gCAAgC;AAAA,EAC3C,cAAc;AAChB;AAmBO,IAAM,mBAAmB;AAAA,EAC9B,MAAM;AAAA,EACN,SAAS;AAAA,EACT,MAAM;AAAA,EACN,cAAc;AAAA,EACd,QAAQ;AACV;AAuCO,IAAM,oBAAoB;AAAA,EAC/B,YAAY;AAAA,EACZ,SAAS;AACX;AA+EO,IAAM,uCAAuC;AAAA,EAClD,wCAAwC;AAAA,EACxC,mCAAmC;AACrC;AAgFO,IAAM,sDAAsD;AAAA,EACjE,eAAe;AAAA,EACf,gBAAgB;AAAA,EAChB,gBAAgB;AAAA,EAChB,iBAAiB;AACnB;","names":[]}
@@ -149,44 +149,6 @@ var useDeleteOrganisation = (options) => {
149
149
  const mutationOptions = getDeleteOrganisationMutationOptions(options);
150
150
  return _reactquery.useMutation.call(void 0, mutationOptions);
151
151
  };
152
- var getOrganisationCharges = (orgId, params, options, signal) => {
153
- return _chunkTKLTUR4Rcjs.customInstance.call(void 0,
154
- {
155
- url: `/organisation/${orgId}/charges`,
156
- method: "GET",
157
- params,
158
- signal
159
- },
160
- options
161
- );
162
- };
163
- var getGetOrganisationChargesQueryKey = (orgId, params) => {
164
- return ["account-server-api", `/organisation/${orgId}/charges`, ...params ? [params] : []];
165
- };
166
- var getGetOrganisationChargesQueryOptions = (orgId, params, options) => {
167
- const { query: queryOptions, request: requestOptions } = _nullishCoalesce(options, () => ( {}));
168
- const queryKey = _nullishCoalesce((queryOptions == null ? void 0 : queryOptions.queryKey), () => ( getGetOrganisationChargesQueryKey(orgId, params)));
169
- const queryFn = ({ signal }) => getOrganisationCharges(orgId, params, requestOptions, signal);
170
- return { queryKey, queryFn, enabled: !!orgId, ...queryOptions };
171
- };
172
- var useGetOrganisationCharges = (orgId, params, options) => {
173
- const queryOptions = getGetOrganisationChargesQueryOptions(orgId, params, options);
174
- const query = _reactquery.useQuery.call(void 0, queryOptions);
175
- query.queryKey = queryOptions.queryKey;
176
- return query;
177
- };
178
- var getGetOrganisationChargesSuspenseQueryOptions = (orgId, params, options) => {
179
- const { query: queryOptions, request: requestOptions } = _nullishCoalesce(options, () => ( {}));
180
- const queryKey = _nullishCoalesce((queryOptions == null ? void 0 : queryOptions.queryKey), () => ( getGetOrganisationChargesQueryKey(orgId, params)));
181
- const queryFn = ({ signal }) => getOrganisationCharges(orgId, params, requestOptions, signal);
182
- return { queryKey, queryFn, enabled: !!orgId, ...queryOptions };
183
- };
184
- var useGetOrganisationChargesSuspense = (orgId, params, options) => {
185
- const queryOptions = getGetOrganisationChargesSuspenseQueryOptions(orgId, params, options);
186
- const query = _reactquery.useSuspenseQuery.call(void 0, queryOptions);
187
- query.queryKey = queryOptions.queryKey;
188
- return query;
189
- };
190
152
  var getDefaultOrganisation = (options, signal) => {
191
153
  return _chunkTKLTUR4Rcjs.customInstance.call(void 0,
192
154
  {
@@ -252,11 +214,5 @@ var useGetDefaultOrganisationSuspense = (options) => {
252
214
 
253
215
 
254
216
 
255
-
256
-
257
-
258
-
259
-
260
-
261
- exports.createOrganisation = createOrganisation; exports.deleteOrganisation = deleteOrganisation; exports.getCreateOrganisationMutationOptions = getCreateOrganisationMutationOptions; exports.getDefaultOrganisation = getDefaultOrganisation; exports.getDeleteOrganisationMutationOptions = getDeleteOrganisationMutationOptions; exports.getGetDefaultOrganisationQueryKey = getGetDefaultOrganisationQueryKey; exports.getGetDefaultOrganisationQueryOptions = getGetDefaultOrganisationQueryOptions; exports.getGetDefaultOrganisationSuspenseQueryOptions = getGetDefaultOrganisationSuspenseQueryOptions; exports.getGetOrganisationChargesQueryKey = getGetOrganisationChargesQueryKey; exports.getGetOrganisationChargesQueryOptions = getGetOrganisationChargesQueryOptions; exports.getGetOrganisationChargesSuspenseQueryOptions = getGetOrganisationChargesSuspenseQueryOptions; exports.getGetOrganisationQueryKey = getGetOrganisationQueryKey; exports.getGetOrganisationQueryOptions = getGetOrganisationQueryOptions; exports.getGetOrganisationSuspenseQueryOptions = getGetOrganisationSuspenseQueryOptions; exports.getGetOrganisationsQueryKey = getGetOrganisationsQueryKey; exports.getGetOrganisationsQueryOptions = getGetOrganisationsQueryOptions; exports.getGetOrganisationsSuspenseQueryOptions = getGetOrganisationsSuspenseQueryOptions; exports.getOrganisation = getOrganisation; exports.getOrganisationCharges = getOrganisationCharges; exports.getOrganisations = getOrganisations; exports.getPatchOrganisationMutationOptions = getPatchOrganisationMutationOptions; exports.patchOrganisation = patchOrganisation; exports.useCreateOrganisation = useCreateOrganisation; exports.useDeleteOrganisation = useDeleteOrganisation; exports.useGetDefaultOrganisation = useGetDefaultOrganisation; exports.useGetDefaultOrganisationSuspense = useGetDefaultOrganisationSuspense; exports.useGetOrganisation = useGetOrganisation; exports.useGetOrganisationCharges = useGetOrganisationCharges; exports.useGetOrganisationChargesSuspense = useGetOrganisationChargesSuspense; exports.useGetOrganisationSuspense = useGetOrganisationSuspense; exports.useGetOrganisations = useGetOrganisations; exports.useGetOrganisationsSuspense = useGetOrganisationsSuspense; exports.usePatchOrganisation = usePatchOrganisation;
217
+ exports.createOrganisation = createOrganisation; exports.deleteOrganisation = deleteOrganisation; exports.getCreateOrganisationMutationOptions = getCreateOrganisationMutationOptions; exports.getDefaultOrganisation = getDefaultOrganisation; exports.getDeleteOrganisationMutationOptions = getDeleteOrganisationMutationOptions; exports.getGetDefaultOrganisationQueryKey = getGetDefaultOrganisationQueryKey; exports.getGetDefaultOrganisationQueryOptions = getGetDefaultOrganisationQueryOptions; exports.getGetDefaultOrganisationSuspenseQueryOptions = getGetDefaultOrganisationSuspenseQueryOptions; exports.getGetOrganisationQueryKey = getGetOrganisationQueryKey; exports.getGetOrganisationQueryOptions = getGetOrganisationQueryOptions; exports.getGetOrganisationSuspenseQueryOptions = getGetOrganisationSuspenseQueryOptions; exports.getGetOrganisationsQueryKey = getGetOrganisationsQueryKey; exports.getGetOrganisationsQueryOptions = getGetOrganisationsQueryOptions; exports.getGetOrganisationsSuspenseQueryOptions = getGetOrganisationsSuspenseQueryOptions; exports.getOrganisation = getOrganisation; exports.getOrganisations = getOrganisations; exports.getPatchOrganisationMutationOptions = getPatchOrganisationMutationOptions; exports.patchOrganisation = patchOrganisation; exports.useCreateOrganisation = useCreateOrganisation; exports.useDeleteOrganisation = useDeleteOrganisation; exports.useGetDefaultOrganisation = useGetDefaultOrganisation; exports.useGetDefaultOrganisationSuspense = useGetDefaultOrganisationSuspense; exports.useGetOrganisation = useGetOrganisation; exports.useGetOrganisationSuspense = useGetOrganisationSuspense; exports.useGetOrganisations = useGetOrganisations; exports.useGetOrganisationsSuspense = useGetOrganisationsSuspense; exports.usePatchOrganisation = usePatchOrganisation;
262
218
  //# sourceMappingURL=organisation.cjs.map
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/organisation/organisation.ts"],"names":[],"mappings":";;;;;AAUA;AAAA,EACE;AAAA,EACA;AAAA,EACA;AAAA,OACK;AAoCA,IAAM,mBAAmB,CAE/B,SAAiD,WAC7C;AAGC,SAAO;AAAA,IACP;AAAA,MAAC,KAAK;AAAA,MAAiB,QAAQ;AAAA,MAAO;AAAA,IACxC;AAAA,IACE;AAAA,EAAO;AACT;AAGG,IAAM,8BAA8B,MAAM;AAC7C,SAAO,CAAC,sBAAsB,eAAe;AAC7C;AAGG,IAAM,kCAAkC,CAA4F,YACtI;AAEL,QAAM,EAAC,OAAO,cAAc,SAAS,eAAc,IAAI,WAAW,CAAC;AAEjE,QAAM,YAAY,6CAAc,aAAY,4BAA4B;AAItE,QAAM,UAAuE,CAAC,EAAE,OAAO,MAAM,iBAAiB,gBAAgB,MAAM;AAMrI,SAAQ,EAAE,UAAU,SAAS,GAAG,aAAY;AAC/C;AAQO,IAAM,sBAAsB,CACjC,YAE8D;AAE9D,QAAM,eAAe,gCAAgC,OAAO;AAE5D,QAAM,QAAQ,SAAS,YAAY;AAEnC,QAAM,WAAW,aAAa;AAE9B,SAAO;AACT;AAIO,IAAM,0CAA0C,CAA4F,YAC9I;AAEL,QAAM,EAAC,OAAO,cAAc,SAAS,eAAc,IAA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,GAAG,aAAY;AAC/C;AAQO,IAAM,4BAA4B,CACvC,YAE8D;AAE9D,QAAM,eAAe,sCAAsC,OAAO;AAElE,QAAM,QAAQ,SAAS,YAAY;AAEnC,QAAM,WAAW,aAAa;AAE9B,SAAO;AACT;AAIO,IAAM,gDAAgD,CAAkG,YAC1J;AAEL,QAAM,EAAC,OAAO,cAAc,SAAS,eAAc,IAAI,WAAW,CAAC;AAEjE,QAAM,YAAY,6CAAc,aAAY,kCAAkC;AAI5E,QAAM,UAA6E,CAAC,EAAE,OAAO,MAAM,uBAAuB,gBAAgB,MAAM;AAMjJ,SAAQ,EAAE,UAAU,SAAS,GAAG,aAAY;AAC/C;AAQO,IAAM,oCAAoC,CAC/C,YAEsE;AAEtE,QAAM,eAAe,8CAA8C,OAAO;AAE1E,QAAM,QAAQ,iBAAiB,YAAY;AAE3C,QAAM,WAAW,aAAa;AAE9B,SAAO;AACT","sourcesContent":["/**\n * Generated by orval v6.25.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: 2.4\n */\nimport {\n useMutation,\n useQuery,\n useSuspenseQuery\n} from '@tanstack/react-query'\nimport type {\n MutationFunction,\n QueryFunction,\n QueryKey,\n UseMutationOptions,\n UseQueryOptions,\n UseQueryResult,\n UseSuspenseQueryOptions,\n UseSuspenseQueryResult\n} from '@tanstack/react-query'\nimport type {\n AsError,\n GetOrganisationChargesParams,\n OrganisationAllDetail,\n OrganisationChargesGetResponse,\n OrganisationGetDefaultResponse,\n OrganisationPatchBodyBody,\n OrganisationPostBodyBody,\n OrganisationPostResponse,\n OrganisationsGetResponse\n} from '../account-server-api.schemas'\nimport { customInstance } from '.././custom-instance';\nimport type { ErrorType } from '.././custom-instance';\n\n\ntype SecondParameter<T extends (...args: any) => any> = Parameters<T>[1];\n\n\n/**\n * Gets all the Organisations that you are a member of.\n\nYou can see an Organisation if you are a member of it, the owner (creator) of it, or if you are an admin user.\n\n * @summary Gets Organisations\n */\nexport const getOrganisations = (\n \n options?: SecondParameter<typeof customInstance>,signal?: AbortSignal\n) => {\n \n \n return customInstance<OrganisationsGetResponse>(\n {url: `/organisation`, method: 'GET', signal\n },\n options);\n }\n \n\nexport const getGetOrganisationsQueryKey = () => {\n return [\"account-server-api\", `/organisation`] as const;\n }\n\n \nexport const getGetOrganisationsQueryOptions = <TData = Awaited<ReturnType<typeof getOrganisations>>, TError = ErrorType<void | AsError>>( options?: { query?:Partial<UseQueryOptions<Awaited<ReturnType<typeof getOrganisations>>, TError, TData>>, request?: SecondParameter<typeof customInstance>}\n) => {\n\nconst {query: queryOptions, request: requestOptions} = options ?? {};\n\n const queryKey = queryOptions?.queryKey ?? getGetOrganisationsQueryKey();\n\n \n\n const queryFn: QueryFunction<Awaited<ReturnType<typeof getOrganisations>>> = ({ signal }) => getOrganisations(requestOptions, signal);\n\n \n\n \n\n return { queryKey, queryFn, ...queryOptions} as UseQueryOptions<Awaited<ReturnType<typeof getOrganisations>>, TError, TData> & { queryKey: QueryKey }\n}\n\nexport type GetOrganisationsQueryResult = NonNullable<Awaited<ReturnType<typeof getOrganisations>>>\nexport type GetOrganisationsQueryError = ErrorType<void | AsError>\n\n/**\n * @summary Gets Organisations\n */\nexport const useGetOrganisations = <TData = Awaited<ReturnType<typeof getOrganisations>>, TError = ErrorType<void | AsError>>(\n options?: { query?:Partial<UseQueryOptions<Awaited<ReturnType<typeof getOrganisations>>, TError, TData>>, request?: SecondParameter<typeof customInstance>}\n\n ): UseQueryResult<TData, TError> & { queryKey: QueryKey } => {\n\n const queryOptions = getGetOrganisationsQueryOptions(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\nexport const getGetOrganisationsSuspenseQueryOptions = <TData = Awaited<ReturnType<typeof getOrganisations>>, TError = ErrorType<void | AsError>>( options?: { query?:Partial<UseSuspenseQueryOptions<Awaited<ReturnType<typeof getOrganisations>>, TError, TData>>, request?: SecondParameter<typeof customInstance>}\n) => {\n\nconst {query: queryOptions, request: requestOptions} = options ?? {};\n\n const queryKey = queryOptions?.queryKey ?? getGetOrganisationsQueryKey();\n\n \n\n const queryFn: QueryFunction<Awaited<ReturnType<typeof getOrganisations>>> = ({ signal }) => getOrganisations(requestOptions, signal);\n\n \n\n \n\n return { queryKey, queryFn, ...queryOptions} as UseSuspenseQueryOptions<Awaited<ReturnType<typeof getOrganisations>>, TError, TData> & { queryKey: QueryKey }\n}\n\nexport type GetOrganisationsSuspenseQueryResult = NonNullable<Awaited<ReturnType<typeof getOrganisations>>>\nexport type GetOrganisationsSuspenseQueryError = ErrorType<void | AsError>\n\n/**\n * @summary Gets Organisations\n */\nexport const useGetOrganisationsSuspense = <TData = Awaited<ReturnType<typeof getOrganisations>>, TError = ErrorType<void | AsError>>(\n options?: { query?:Partial<UseSuspenseQueryOptions<Awaited<ReturnType<typeof getOrganisations>>, TError, TData>>, request?: SecondParameter<typeof customInstance>}\n\n ): UseSuspenseQueryResult<TData, TError> & { queryKey: QueryKey } => {\n\n const queryOptions = getGetOrganisationsSuspenseQueryOptions(options)\n\n const query = useSuspenseQuery(queryOptions) as UseSuspenseQueryResult<TData, TError> & { queryKey: QueryKey };\n\n query.queryKey = queryOptions.queryKey ;\n\n return query;\n}\n\n\n\n/**\n * Creates a new Organisation.\n\nThe **User** who creates the Organisation becomes the **Owner** of the Organisation. They are considered a *Member* (**User**) of the Organisation but are not present in the list of users, which a separate list of users explicitly added to the Organisation by the Owner or another Organisation User.\n\nYou need admin rights to use this method\n\n * @summary Create a new organisation\n */\nexport const createOrganisation = (\n organisationPostBodyBody: OrganisationPostBodyBody,\n options?: SecondParameter<typeof customInstance>,) => {\n \n \n return customInstance<OrganisationPostResponse>(\n {url: `/organisation`, method: 'POST',\n headers: {'Content-Type': 'application/json', },\n data: organisationPostBodyBody\n },\n options);\n }\n \n\n\nexport const getCreateOrganisationMutationOptions = <TError = ErrorType<AsError | void>,\n TContext = unknown>(options?: { mutation?:UseMutationOptions<Awaited<ReturnType<typeof createOrganisation>>, TError,{data: OrganisationPostBodyBody}, TContext>, request?: SecondParameter<typeof customInstance>}\n): UseMutationOptions<Awaited<ReturnType<typeof createOrganisation>>, TError,{data: OrganisationPostBodyBody}, TContext> => {\n const {mutation: mutationOptions, request: requestOptions} = options ?? {};\n\n \n\n\n const mutationFn: MutationFunction<Awaited<ReturnType<typeof createOrganisation>>, {data: OrganisationPostBodyBody}> = (props) => {\n const {data} = props ?? {};\n\n return createOrganisation(data,requestOptions)\n }\n\n \n\n\n return { mutationFn, ...mutationOptions }}\n\n export type CreateOrganisationMutationResult = NonNullable<Awaited<ReturnType<typeof createOrganisation>>>\n export type CreateOrganisationMutationBody = OrganisationPostBodyBody\n export type CreateOrganisationMutationError = ErrorType<AsError | void>\n\n /**\n * @summary Create a new organisation\n */\nexport const useCreateOrganisation = <TError = ErrorType<AsError | void>,\n TContext = unknown>(options?: { mutation?:UseMutationOptions<Awaited<ReturnType<typeof createOrganisation>>, TError,{data: OrganisationPostBodyBody}, TContext>, request?: SecondParameter<typeof customInstance>}\n) => {\n\n const mutationOptions = getCreateOrganisationMutationOptions(options);\n\n return useMutation(mutationOptions);\n }\n /**\n * Gets an Organisation. To see the Organisation you need admin rights or need to be a member of the Organisation or are its *creator*.\n\nMembers of an Organisation's **Unit** do not have access to the Organisation.\n\n * @summary Gets an Organisation\n */\nexport const getOrganisation = (\n orgId: string,\n options?: SecondParameter<typeof customInstance>,signal?: AbortSignal\n) => {\n \n \n return customInstance<OrganisationAllDetail>(\n {url: `/organisation/${orgId}`, method: 'GET', signal\n },\n options);\n }\n \n\nexport const getGetOrganisationQueryKey = (orgId: string,) => {\n return [\"account-server-api\", `/organisation/${orgId}`] as const;\n }\n\n \nexport const getGetOrganisationQueryOptions = <TData = Awaited<ReturnType<typeof getOrganisation>>, TError = ErrorType<void | AsError>>(orgId: string, options?: { query?:Partial<UseQueryOptions<Awaited<ReturnType<typeof getOrganisation>>, TError, TData>>, request?: SecondParameter<typeof customInstance>}\n) => {\n\nconst {query: queryOptions, request: requestOptions} = options ?? {};\n\n const queryKey = queryOptions?.queryKey ?? getGetOrganisationQueryKey(orgId);\n\n \n\n const queryFn: QueryFunction<Awaited<ReturnType<typeof getOrganisation>>> = ({ signal }) => getOrganisation(orgId, requestOptions, signal);\n\n \n\n \n\n return { queryKey, queryFn, enabled: !!(orgId), ...queryOptions} as UseQueryOptions<Awaited<ReturnType<typeof getOrganisation>>, TError, TData> & { queryKey: QueryKey }\n}\n\nexport type GetOrganisationQueryResult = NonNullable<Awaited<ReturnType<typeof getOrganisation>>>\nexport type GetOrganisationQueryError = ErrorType<void | AsError>\n\n/**\n * @summary Gets an Organisation\n */\nexport const useGetOrganisation = <TData = Awaited<ReturnType<typeof getOrganisation>>, TError = ErrorType<void | AsError>>(\n orgId: string, options?: { query?:Partial<UseQueryOptions<Awaited<ReturnType<typeof getOrganisation>>, TError, TData>>, request?: SecondParameter<typeof customInstance>}\n\n ): UseQueryResult<TData, TError> & { queryKey: QueryKey } => {\n\n const queryOptions = getGetOrganisationQueryOptions(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\nexport const getGetOrganisationSuspenseQueryOptions = <TData = Awaited<ReturnType<typeof getOrganisation>>, TError = ErrorType<void | AsError>>(orgId: string, options?: { query?:Partial<UseSuspenseQueryOptions<Awaited<ReturnType<typeof getOrganisation>>, TError, TData>>, request?: SecondParameter<typeof customInstance>}\n) => {\n\nconst {query: queryOptions, request: requestOptions} = options ?? {};\n\n const queryKey = queryOptions?.queryKey ?? getGetOrganisationQueryKey(orgId);\n\n \n\n const queryFn: QueryFunction<Awaited<ReturnType<typeof getOrganisation>>> = ({ signal }) => getOrganisation(orgId, requestOptions, signal);\n\n \n\n \n\n return { queryKey, queryFn, enabled: !!(orgId), ...queryOptions} as UseSuspenseQueryOptions<Awaited<ReturnType<typeof getOrganisation>>, TError, TData> & { queryKey: QueryKey }\n}\n\nexport type GetOrganisationSuspenseQueryResult = NonNullable<Awaited<ReturnType<typeof getOrganisation>>>\nexport type GetOrganisationSuspenseQueryError = ErrorType<void | AsError>\n\n/**\n * @summary Gets an Organisation\n */\nexport const useGetOrganisationSuspense = <TData = Awaited<ReturnType<typeof getOrganisation>>, TError = ErrorType<void | AsError>>(\n orgId: string, options?: { query?:Partial<UseSuspenseQueryOptions<Awaited<ReturnType<typeof getOrganisation>>, TError, TData>>, request?: SecondParameter<typeof customInstance>}\n\n ): UseSuspenseQueryResult<TData, TError> & { queryKey: QueryKey } => {\n\n const queryOptions = getGetOrganisationSuspenseQueryOptions(orgId,options)\n\n const query = useSuspenseQuery(queryOptions) as UseSuspenseQueryResult<TData, TError> & { queryKey: QueryKey };\n\n query.queryKey = queryOptions.queryKey ;\n\n return query;\n}\n\n\n\n/**\n * Used to update existing Organisation.\n\nYou have to be a member of the **Organisation**, its creator, or an administrator to patch an Organisation.\n\n * @summary Adjust an existing Organisation\n */\nexport const patchOrganisation = (\n orgId: string,\n organisationPatchBodyBody: OrganisationPatchBodyBody,\n options?: SecondParameter<typeof customInstance>,) => {\n \n \n return customInstance<void>(\n {url: `/organisation/${orgId}`, method: 'PATCH',\n headers: {'Content-Type': 'application/json', },\n data: organisationPatchBodyBody\n },\n options);\n }\n \n\n\nexport const getPatchOrganisationMutationOptions = <TError = ErrorType<AsError>,\n TContext = unknown>(options?: { mutation?:UseMutationOptions<Awaited<ReturnType<typeof patchOrganisation>>, TError,{orgId: string;data: OrganisationPatchBodyBody}, TContext>, request?: SecondParameter<typeof customInstance>}\n): UseMutationOptions<Awaited<ReturnType<typeof patchOrganisation>>, TError,{orgId: string;data: OrganisationPatchBodyBody}, TContext> => {\n const {mutation: mutationOptions, request: requestOptions} = options ?? {};\n\n \n\n\n const mutationFn: MutationFunction<Awaited<ReturnType<typeof patchOrganisation>>, {orgId: string;data: OrganisationPatchBodyBody}> = (props) => {\n const {orgId,data} = props ?? {};\n\n return patchOrganisation(orgId,data,requestOptions)\n }\n\n \n\n\n return { mutationFn, ...mutationOptions }}\n\n export type PatchOrganisationMutationResult = NonNullable<Awaited<ReturnType<typeof patchOrganisation>>>\n export type PatchOrganisationMutationBody = OrganisationPatchBodyBody\n export type PatchOrganisationMutationError = ErrorType<AsError>\n\n /**\n * @summary Adjust an existing Organisation\n */\nexport const usePatchOrganisation = <TError = ErrorType<AsError>,\n TContext = unknown>(options?: { mutation?:UseMutationOptions<Awaited<ReturnType<typeof patchOrganisation>>, TError,{orgId: string;data: OrganisationPatchBodyBody}, TContext>, request?: SecondParameter<typeof customInstance>}\n) => {\n\n const mutationOptions = getPatchOrganisationMutationOptions(options);\n\n return useMutation(mutationOptions);\n }\n /**\n * Before an Organisation can be deleted all its underlying **Units** must also be deleted, remembering that **Units** that have undeleted **Products** cannot be deleted.\n\nYou need admin rights to use this method\n\n * @summary Deletes an Organisation\n */\nexport const deleteOrganisation = (\n orgId: string,\n options?: SecondParameter<typeof customInstance>,) => {\n \n \n return customInstance<void>(\n {url: `/organisation/${orgId}`, method: 'DELETE'\n },\n options);\n }\n \n\n\nexport const getDeleteOrganisationMutationOptions = <TError = ErrorType<AsError>,\n TContext = unknown>(options?: { mutation?:UseMutationOptions<Awaited<ReturnType<typeof deleteOrganisation>>, TError,{orgId: string}, TContext>, request?: SecondParameter<typeof customInstance>}\n): UseMutationOptions<Awaited<ReturnType<typeof deleteOrganisation>>, TError,{orgId: string}, TContext> => {\n const {mutation: mutationOptions, request: requestOptions} = options ?? {};\n\n \n\n\n const mutationFn: MutationFunction<Awaited<ReturnType<typeof deleteOrganisation>>, {orgId: string}> = (props) => {\n const {orgId} = props ?? {};\n\n return deleteOrganisation(orgId,requestOptions)\n }\n\n \n\n\n return { mutationFn, ...mutationOptions }}\n\n export type DeleteOrganisationMutationResult = NonNullable<Awaited<ReturnType<typeof deleteOrganisation>>>\n \n export type DeleteOrganisationMutationError = ErrorType<AsError>\n\n /**\n * @summary Deletes an Organisation\n */\nexport const useDeleteOrganisation = <TError = ErrorType<AsError>,\n TContext = unknown>(options?: { mutation?:UseMutationOptions<Awaited<ReturnType<typeof deleteOrganisation>>, TError,{orgId: string}, TContext>, request?: SecondParameter<typeof customInstance>}\n) => {\n\n const mutationOptions = getDeleteOrganisationMutationOptions(options);\n\n return useMutation(mutationOptions);\n }\n /**\n * Gets a Organisation charges.\n\nThe Organisation cannot be the **Default Organisation** and you need to be a member of the Organisation to use this endpoint\n\n * @summary Gets charges for all Units in an Organisation\n */\nexport const getOrganisationCharges = (\n orgId: string,\n params?: GetOrganisationChargesParams,\n options?: SecondParameter<typeof customInstance>,signal?: AbortSignal\n) => {\n \n \n return customInstance<OrganisationChargesGetResponse>(\n {url: `/organisation/${orgId}/charges`, method: 'GET',\n params, signal\n },\n options);\n }\n \n\nexport const getGetOrganisationChargesQueryKey = (orgId: string,\n params?: GetOrganisationChargesParams,) => {\n return [\"account-server-api\", `/organisation/${orgId}/charges`, ...(params ? [params]: [])] as const;\n }\n\n \nexport const getGetOrganisationChargesQueryOptions = <TData = Awaited<ReturnType<typeof getOrganisationCharges>>, TError = ErrorType<void | AsError>>(orgId: string,\n params?: GetOrganisationChargesParams, options?: { query?:Partial<UseQueryOptions<Awaited<ReturnType<typeof getOrganisationCharges>>, TError, TData>>, request?: SecondParameter<typeof customInstance>}\n) => {\n\nconst {query: queryOptions, request: requestOptions} = options ?? {};\n\n const queryKey = queryOptions?.queryKey ?? getGetOrganisationChargesQueryKey(orgId,params);\n\n \n\n const queryFn: QueryFunction<Awaited<ReturnType<typeof getOrganisationCharges>>> = ({ signal }) => getOrganisationCharges(orgId,params, requestOptions, signal);\n\n \n\n \n\n return { queryKey, queryFn, enabled: !!(orgId), ...queryOptions} as UseQueryOptions<Awaited<ReturnType<typeof getOrganisationCharges>>, TError, TData> & { queryKey: QueryKey }\n}\n\nexport type GetOrganisationChargesQueryResult = NonNullable<Awaited<ReturnType<typeof getOrganisationCharges>>>\nexport type GetOrganisationChargesQueryError = ErrorType<void | AsError>\n\n/**\n * @summary Gets charges for all Units in an Organisation\n */\nexport const useGetOrganisationCharges = <TData = Awaited<ReturnType<typeof getOrganisationCharges>>, TError = ErrorType<void | AsError>>(\n orgId: string,\n params?: GetOrganisationChargesParams, options?: { query?:Partial<UseQueryOptions<Awaited<ReturnType<typeof getOrganisationCharges>>, TError, TData>>, request?: SecondParameter<typeof customInstance>}\n\n ): UseQueryResult<TData, TError> & { queryKey: QueryKey } => {\n\n const queryOptions = getGetOrganisationChargesQueryOptions(orgId,params,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\nexport const getGetOrganisationChargesSuspenseQueryOptions = <TData = Awaited<ReturnType<typeof getOrganisationCharges>>, TError = ErrorType<void | AsError>>(orgId: string,\n params?: GetOrganisationChargesParams, options?: { query?:Partial<UseSuspenseQueryOptions<Awaited<ReturnType<typeof getOrganisationCharges>>, TError, TData>>, request?: SecondParameter<typeof customInstance>}\n) => {\n\nconst {query: queryOptions, request: requestOptions} = options ?? {};\n\n const queryKey = queryOptions?.queryKey ?? getGetOrganisationChargesQueryKey(orgId,params);\n\n \n\n const queryFn: QueryFunction<Awaited<ReturnType<typeof getOrganisationCharges>>> = ({ signal }) => getOrganisationCharges(orgId,params, requestOptions, signal);\n\n \n\n \n\n return { queryKey, queryFn, enabled: !!(orgId), ...queryOptions} as UseSuspenseQueryOptions<Awaited<ReturnType<typeof getOrganisationCharges>>, TError, TData> & { queryKey: QueryKey }\n}\n\nexport type GetOrganisationChargesSuspenseQueryResult = NonNullable<Awaited<ReturnType<typeof getOrganisationCharges>>>\nexport type GetOrganisationChargesSuspenseQueryError = ErrorType<void | AsError>\n\n/**\n * @summary Gets charges for all Units in an Organisation\n */\nexport const useGetOrganisationChargesSuspense = <TData = Awaited<ReturnType<typeof getOrganisationCharges>>, TError = ErrorType<void | AsError>>(\n orgId: string,\n params?: GetOrganisationChargesParams, options?: { query?:Partial<UseSuspenseQueryOptions<Awaited<ReturnType<typeof getOrganisationCharges>>, TError, TData>>, request?: SecondParameter<typeof customInstance>}\n\n ): UseSuspenseQueryResult<TData, TError> & { queryKey: QueryKey } => {\n\n const queryOptions = getGetOrganisationChargesSuspenseQueryOptions(orgId,params,options)\n\n const query = useSuspenseQuery(queryOptions) as UseSuspenseQueryResult<TData, TError> & { queryKey: QueryKey };\n\n query.queryKey = queryOptions.queryKey ;\n\n return query;\n}\n\n\n\n/**\n * Gets the Default Organisation, a built-in Organisation used exclusively for **Personal Units**.\n\nAny authorised user can see the Default Organisation.\n\n * @summary Gets the Default Organisation\n */\nexport const getDefaultOrganisation = (\n \n options?: SecondParameter<typeof customInstance>,signal?: AbortSignal\n) => {\n \n \n return customInstance<OrganisationGetDefaultResponse>(\n {url: `/organisation/default`, method: 'GET', signal\n },\n options);\n }\n \n\nexport const getGetDefaultOrganisationQueryKey = () => {\n return [\"account-server-api\", `/organisation/default`] as const;\n }\n\n \nexport const getGetDefaultOrganisationQueryOptions = <TData = Awaited<ReturnType<typeof getDefaultOrganisation>>, TError = ErrorType<void | AsError>>( options?: { query?:Partial<UseQueryOptions<Awaited<ReturnType<typeof getDefaultOrganisation>>, TError, TData>>, request?: SecondParameter<typeof customInstance>}\n) => {\n\nconst {query: queryOptions, request: requestOptions} = options ?? {};\n\n const queryKey = queryOptions?.queryKey ?? getGetDefaultOrganisationQueryKey();\n\n \n\n const queryFn: QueryFunction<Awaited<ReturnType<typeof getDefaultOrganisation>>> = ({ signal }) => getDefaultOrganisation(requestOptions, signal);\n\n \n\n \n\n return { queryKey, queryFn, ...queryOptions} as UseQueryOptions<Awaited<ReturnType<typeof getDefaultOrganisation>>, TError, TData> & { queryKey: QueryKey }\n}\n\nexport type GetDefaultOrganisationQueryResult = NonNullable<Awaited<ReturnType<typeof getDefaultOrganisation>>>\nexport type GetDefaultOrganisationQueryError = ErrorType<void | AsError>\n\n/**\n * @summary Gets the Default Organisation\n */\nexport const useGetDefaultOrganisation = <TData = Awaited<ReturnType<typeof getDefaultOrganisation>>, TError = ErrorType<void | AsError>>(\n options?: { query?:Partial<UseQueryOptions<Awaited<ReturnType<typeof getDefaultOrganisation>>, TError, TData>>, request?: SecondParameter<typeof customInstance>}\n\n ): UseQueryResult<TData, TError> & { queryKey: QueryKey } => {\n\n const queryOptions = getGetDefaultOrganisationQueryOptions(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\nexport const getGetDefaultOrganisationSuspenseQueryOptions = <TData = Awaited<ReturnType<typeof getDefaultOrganisation>>, TError = ErrorType<void | AsError>>( options?: { query?:Partial<UseSuspenseQueryOptions<Awaited<ReturnType<typeof getDefaultOrganisation>>, TError, TData>>, request?: SecondParameter<typeof customInstance>}\n) => {\n\nconst {query: queryOptions, request: requestOptions} = options ?? {};\n\n const queryKey = queryOptions?.queryKey ?? getGetDefaultOrganisationQueryKey();\n\n \n\n const queryFn: QueryFunction<Awaited<ReturnType<typeof getDefaultOrganisation>>> = ({ signal }) => getDefaultOrganisation(requestOptions, signal);\n\n \n\n \n\n return { queryKey, queryFn, ...queryOptions} as UseSuspenseQueryOptions<Awaited<ReturnType<typeof getDefaultOrganisation>>, TError, TData> & { queryKey: QueryKey }\n}\n\nexport type GetDefaultOrganisationSuspenseQueryResult = NonNullable<Awaited<ReturnType<typeof getDefaultOrganisation>>>\nexport type GetDefaultOrganisationSuspenseQueryError = ErrorType<void | AsError>\n\n/**\n * @summary Gets the Default Organisation\n */\nexport const useGetDefaultOrganisationSuspense = <TData = Awaited<ReturnType<typeof getDefaultOrganisation>>, TError = ErrorType<void | AsError>>(\n options?: { query?:Partial<UseSuspenseQueryOptions<Awaited<ReturnType<typeof getDefaultOrganisation>>, TError, TData>>, request?: SecondParameter<typeof customInstance>}\n\n ): UseSuspenseQueryResult<TData, TError> & { queryKey: QueryKey } => {\n\n const queryOptions = getGetDefaultOrganisationSuspenseQueryOptions(options)\n\n const query = useSuspenseQuery(queryOptions) as UseSuspenseQueryResult<TData, TError> & { queryKey: QueryKey };\n\n query.queryKey = queryOptions.queryKey ;\n\n return query;\n}\n\n\n\n"]}
1
+ {"version":3,"sources":["../../src/organisation/organisation.ts"],"names":[],"mappings":";;;;;AAUA;AAAA,EACE;AAAA,EACA;AAAA,EACA;AAAA,OACK;AAkCA,IAAM,mBAAmB,CAE/B,SAAiD,WAC7C;AAGC,SAAO;AAAA,IACP;AAAA,MAAC,KAAK;AAAA,MAAiB,QAAQ;AAAA,MAAO;AAAA,IACxC;AAAA,IACE;AAAA,EAAO;AACT;AAGG,IAAM,8BAA8B,MAAM;AAC7C,SAAO,CAAC,sBAAsB,eAAe;AAC7C;AAGG,IAAM,kCAAkC,CAA4F,YACtI;AAEL,QAAM,EAAC,OAAO,cAAc,SAAS,eAAc,IAAI,WAAW,CAAC;AAEjE,QAAM,YAAY,6CAAc,aAAY,4BAA4B;AAItE,QAAM,UAAuE,CAAC,EAAE,OAAO,MAAM,iBAAiB,gBAAgB,MAAM;AAMrI,SAAQ,EAAE,UAAU,SAAS,GAAG,aAAY;AAC/C;AAQO,IAAM,sBAAsB,CACjC,YAE8D;AAE9D,QAAM,eAAe,gCAAgC,OAAO;AAE5D,QAAM,QAAQ,SAAS,YAAY;AAEnC,QAAM,WAAW,aAAa;AAE9B,SAAO;AACT;AAIO,IAAM,0CAA0C,CAA4F,YAC9I;AAEL,QAAM,EAAC,OAAO,cAAc,SAAS,eAAc,IAAI,WAAW,CAAC;AAEjE,QAAM,YAAY,6CAAc,aAAY,4BAA4B;AAItE,QAAM,UAAuE,CAAC,EAAE,OAAO,MAAM,iBAAiB,gBAAgB,MAAM;AAMrI,SAAQ,EAAE,UAAU,SAAS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AAc,SAAS,eAAc,IAAI,WAAW,CAAC;AAEjE,QAAM,YAAY,6CAAc,aAAY,kCAAkC;AAI5E,QAAM,UAA6E,CAAC,EAAE,OAAO,MAAM,uBAAuB,gBAAgB,MAAM;AAMjJ,SAAQ,EAAE,UAAU,SAAS,GAAG,aAAY;AAC/C;AAQO,IAAM,oCAAoC,CAC/C,YAEsE;AAEtE,QAAM,eAAe,8CAA8C,OAAO;AAE1E,QAAM,QAAQ,iBAAiB,YAAY;AAE3C,QAAM,WAAW,aAAa;AAE9B,SAAO;AACT","sourcesContent":["/**\n * Generated by orval v6.25.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: 2.4\n */\nimport {\n useMutation,\n useQuery,\n useSuspenseQuery\n} from '@tanstack/react-query'\nimport type {\n MutationFunction,\n QueryFunction,\n QueryKey,\n UseMutationOptions,\n UseQueryOptions,\n UseQueryResult,\n UseSuspenseQueryOptions,\n UseSuspenseQueryResult\n} from '@tanstack/react-query'\nimport type {\n AsError,\n OrganisationAllDetail,\n OrganisationGetDefaultResponse,\n OrganisationPatchBodyBody,\n OrganisationPostBodyBody,\n OrganisationPostResponse,\n OrganisationsGetResponse\n} from '../account-server-api.schemas'\nimport { customInstance } from '.././custom-instance';\nimport type { ErrorType } from '.././custom-instance';\n\n\ntype SecondParameter<T extends (...args: any) => any> = Parameters<T>[1];\n\n\n/**\n * Gets all the Organisations that you are a member of.\n\nYou can see an Organisation if you are a member of it, the owner (creator) of it, or if you are an admin user.\n\n * @summary Gets Organisations\n */\nexport const getOrganisations = (\n \n options?: SecondParameter<typeof customInstance>,signal?: AbortSignal\n) => {\n \n \n return customInstance<OrganisationsGetResponse>(\n {url: `/organisation`, method: 'GET', signal\n },\n options);\n }\n \n\nexport const getGetOrganisationsQueryKey = () => {\n return [\"account-server-api\", `/organisation`] as const;\n }\n\n \nexport const getGetOrganisationsQueryOptions = <TData = Awaited<ReturnType<typeof getOrganisations>>, TError = ErrorType<void | AsError>>( options?: { query?:Partial<UseQueryOptions<Awaited<ReturnType<typeof getOrganisations>>, TError, TData>>, request?: SecondParameter<typeof customInstance>}\n) => {\n\nconst {query: queryOptions, request: requestOptions} = options ?? {};\n\n const queryKey = queryOptions?.queryKey ?? getGetOrganisationsQueryKey();\n\n \n\n const queryFn: QueryFunction<Awaited<ReturnType<typeof getOrganisations>>> = ({ signal }) => getOrganisations(requestOptions, signal);\n\n \n\n \n\n return { queryKey, queryFn, ...queryOptions} as UseQueryOptions<Awaited<ReturnType<typeof getOrganisations>>, TError, TData> & { queryKey: QueryKey }\n}\n\nexport type GetOrganisationsQueryResult = NonNullable<Awaited<ReturnType<typeof getOrganisations>>>\nexport type GetOrganisationsQueryError = ErrorType<void | AsError>\n\n/**\n * @summary Gets Organisations\n */\nexport const useGetOrganisations = <TData = Awaited<ReturnType<typeof getOrganisations>>, TError = ErrorType<void | AsError>>(\n options?: { query?:Partial<UseQueryOptions<Awaited<ReturnType<typeof getOrganisations>>, TError, TData>>, request?: SecondParameter<typeof customInstance>}\n\n ): UseQueryResult<TData, TError> & { queryKey: QueryKey } => {\n\n const queryOptions = getGetOrganisationsQueryOptions(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\nexport const getGetOrganisationsSuspenseQueryOptions = <TData = Awaited<ReturnType<typeof getOrganisations>>, TError = ErrorType<void | AsError>>( options?: { query?:Partial<UseSuspenseQueryOptions<Awaited<ReturnType<typeof getOrganisations>>, TError, TData>>, request?: SecondParameter<typeof customInstance>}\n) => {\n\nconst {query: queryOptions, request: requestOptions} = options ?? {};\n\n const queryKey = queryOptions?.queryKey ?? getGetOrganisationsQueryKey();\n\n \n\n const queryFn: QueryFunction<Awaited<ReturnType<typeof getOrganisations>>> = ({ signal }) => getOrganisations(requestOptions, signal);\n\n \n\n \n\n return { queryKey, queryFn, ...queryOptions} as UseSuspenseQueryOptions<Awaited<ReturnType<typeof getOrganisations>>, TError, TData> & { queryKey: QueryKey }\n}\n\nexport type GetOrganisationsSuspenseQueryResult = NonNullable<Awaited<ReturnType<typeof getOrganisations>>>\nexport type GetOrganisationsSuspenseQueryError = ErrorType<void | AsError>\n\n/**\n * @summary Gets Organisations\n */\nexport const useGetOrganisationsSuspense = <TData = Awaited<ReturnType<typeof getOrganisations>>, TError = ErrorType<void | AsError>>(\n options?: { query?:Partial<UseSuspenseQueryOptions<Awaited<ReturnType<typeof getOrganisations>>, TError, TData>>, request?: SecondParameter<typeof customInstance>}\n\n ): UseSuspenseQueryResult<TData, TError> & { queryKey: QueryKey } => {\n\n const queryOptions = getGetOrganisationsSuspenseQueryOptions(options)\n\n const query = useSuspenseQuery(queryOptions) as UseSuspenseQueryResult<TData, TError> & { queryKey: QueryKey };\n\n query.queryKey = queryOptions.queryKey ;\n\n return query;\n}\n\n\n\n/**\n * Creates a new Organisation.\n\nThe **User** who creates the Organisation becomes the **Owner** of the Organisation. They are considered a *Member* (**User**) of the Organisation but are not present in the list of users, which a separate list of users explicitly added to the Organisation by the Owner or another Organisation User.\n\nYou need admin rights to use this method\n\n * @summary Create a new organisation\n */\nexport const createOrganisation = (\n organisationPostBodyBody: OrganisationPostBodyBody,\n options?: SecondParameter<typeof customInstance>,) => {\n \n \n return customInstance<OrganisationPostResponse>(\n {url: `/organisation`, method: 'POST',\n headers: {'Content-Type': 'application/json', },\n data: organisationPostBodyBody\n },\n options);\n }\n \n\n\nexport const getCreateOrganisationMutationOptions = <TError = ErrorType<AsError | void>,\n TContext = unknown>(options?: { mutation?:UseMutationOptions<Awaited<ReturnType<typeof createOrganisation>>, TError,{data: OrganisationPostBodyBody}, TContext>, request?: SecondParameter<typeof customInstance>}\n): UseMutationOptions<Awaited<ReturnType<typeof createOrganisation>>, TError,{data: OrganisationPostBodyBody}, TContext> => {\n const {mutation: mutationOptions, request: requestOptions} = options ?? {};\n\n \n\n\n const mutationFn: MutationFunction<Awaited<ReturnType<typeof createOrganisation>>, {data: OrganisationPostBodyBody}> = (props) => {\n const {data} = props ?? {};\n\n return createOrganisation(data,requestOptions)\n }\n\n \n\n\n return { mutationFn, ...mutationOptions }}\n\n export type CreateOrganisationMutationResult = NonNullable<Awaited<ReturnType<typeof createOrganisation>>>\n export type CreateOrganisationMutationBody = OrganisationPostBodyBody\n export type CreateOrganisationMutationError = ErrorType<AsError | void>\n\n /**\n * @summary Create a new organisation\n */\nexport const useCreateOrganisation = <TError = ErrorType<AsError | void>,\n TContext = unknown>(options?: { mutation?:UseMutationOptions<Awaited<ReturnType<typeof createOrganisation>>, TError,{data: OrganisationPostBodyBody}, TContext>, request?: SecondParameter<typeof customInstance>}\n) => {\n\n const mutationOptions = getCreateOrganisationMutationOptions(options);\n\n return useMutation(mutationOptions);\n }\n /**\n * Gets an Organisation. To see the Organisation you need admin rights or need to be a member of the Organisation or are its *creator*.\n\nMembers of an Organisation's **Unit** do not have access to the Organisation.\n\n * @summary Gets an Organisation\n */\nexport const getOrganisation = (\n orgId: string,\n options?: SecondParameter<typeof customInstance>,signal?: AbortSignal\n) => {\n \n \n return customInstance<OrganisationAllDetail>(\n {url: `/organisation/${orgId}`, method: 'GET', signal\n },\n options);\n }\n \n\nexport const getGetOrganisationQueryKey = (orgId: string,) => {\n return [\"account-server-api\", `/organisation/${orgId}`] as const;\n }\n\n \nexport const getGetOrganisationQueryOptions = <TData = Awaited<ReturnType<typeof getOrganisation>>, TError = ErrorType<void | AsError>>(orgId: string, options?: { query?:Partial<UseQueryOptions<Awaited<ReturnType<typeof getOrganisation>>, TError, TData>>, request?: SecondParameter<typeof customInstance>}\n) => {\n\nconst {query: queryOptions, request: requestOptions} = options ?? {};\n\n const queryKey = queryOptions?.queryKey ?? getGetOrganisationQueryKey(orgId);\n\n \n\n const queryFn: QueryFunction<Awaited<ReturnType<typeof getOrganisation>>> = ({ signal }) => getOrganisation(orgId, requestOptions, signal);\n\n \n\n \n\n return { queryKey, queryFn, enabled: !!(orgId), ...queryOptions} as UseQueryOptions<Awaited<ReturnType<typeof getOrganisation>>, TError, TData> & { queryKey: QueryKey }\n}\n\nexport type GetOrganisationQueryResult = NonNullable<Awaited<ReturnType<typeof getOrganisation>>>\nexport type GetOrganisationQueryError = ErrorType<void | AsError>\n\n/**\n * @summary Gets an Organisation\n */\nexport const useGetOrganisation = <TData = Awaited<ReturnType<typeof getOrganisation>>, TError = ErrorType<void | AsError>>(\n orgId: string, options?: { query?:Partial<UseQueryOptions<Awaited<ReturnType<typeof getOrganisation>>, TError, TData>>, request?: SecondParameter<typeof customInstance>}\n\n ): UseQueryResult<TData, TError> & { queryKey: QueryKey } => {\n\n const queryOptions = getGetOrganisationQueryOptions(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\nexport const getGetOrganisationSuspenseQueryOptions = <TData = Awaited<ReturnType<typeof getOrganisation>>, TError = ErrorType<void | AsError>>(orgId: string, options?: { query?:Partial<UseSuspenseQueryOptions<Awaited<ReturnType<typeof getOrganisation>>, TError, TData>>, request?: SecondParameter<typeof customInstance>}\n) => {\n\nconst {query: queryOptions, request: requestOptions} = options ?? {};\n\n const queryKey = queryOptions?.queryKey ?? getGetOrganisationQueryKey(orgId);\n\n \n\n const queryFn: QueryFunction<Awaited<ReturnType<typeof getOrganisation>>> = ({ signal }) => getOrganisation(orgId, requestOptions, signal);\n\n \n\n \n\n return { queryKey, queryFn, enabled: !!(orgId), ...queryOptions} as UseSuspenseQueryOptions<Awaited<ReturnType<typeof getOrganisation>>, TError, TData> & { queryKey: QueryKey }\n}\n\nexport type GetOrganisationSuspenseQueryResult = NonNullable<Awaited<ReturnType<typeof getOrganisation>>>\nexport type GetOrganisationSuspenseQueryError = ErrorType<void | AsError>\n\n/**\n * @summary Gets an Organisation\n */\nexport const useGetOrganisationSuspense = <TData = Awaited<ReturnType<typeof getOrganisation>>, TError = ErrorType<void | AsError>>(\n orgId: string, options?: { query?:Partial<UseSuspenseQueryOptions<Awaited<ReturnType<typeof getOrganisation>>, TError, TData>>, request?: SecondParameter<typeof customInstance>}\n\n ): UseSuspenseQueryResult<TData, TError> & { queryKey: QueryKey } => {\n\n const queryOptions = getGetOrganisationSuspenseQueryOptions(orgId,options)\n\n const query = useSuspenseQuery(queryOptions) as UseSuspenseQueryResult<TData, TError> & { queryKey: QueryKey };\n\n query.queryKey = queryOptions.queryKey ;\n\n return query;\n}\n\n\n\n/**\n * Used to update existing Organisation.\n\nYou have to be a member of the **Organisation**, its creator, or an administrator to patch an Organisation.\n\n * @summary Adjust an existing Organisation\n */\nexport const patchOrganisation = (\n orgId: string,\n organisationPatchBodyBody: OrganisationPatchBodyBody,\n options?: SecondParameter<typeof customInstance>,) => {\n \n \n return customInstance<void>(\n {url: `/organisation/${orgId}`, method: 'PATCH',\n headers: {'Content-Type': 'application/json', },\n data: organisationPatchBodyBody\n },\n options);\n }\n \n\n\nexport const getPatchOrganisationMutationOptions = <TError = ErrorType<AsError>,\n TContext = unknown>(options?: { mutation?:UseMutationOptions<Awaited<ReturnType<typeof patchOrganisation>>, TError,{orgId: string;data: OrganisationPatchBodyBody}, TContext>, request?: SecondParameter<typeof customInstance>}\n): UseMutationOptions<Awaited<ReturnType<typeof patchOrganisation>>, TError,{orgId: string;data: OrganisationPatchBodyBody}, TContext> => {\n const {mutation: mutationOptions, request: requestOptions} = options ?? {};\n\n \n\n\n const mutationFn: MutationFunction<Awaited<ReturnType<typeof patchOrganisation>>, {orgId: string;data: OrganisationPatchBodyBody}> = (props) => {\n const {orgId,data} = props ?? {};\n\n return patchOrganisation(orgId,data,requestOptions)\n }\n\n \n\n\n return { mutationFn, ...mutationOptions }}\n\n export type PatchOrganisationMutationResult = NonNullable<Awaited<ReturnType<typeof patchOrganisation>>>\n export type PatchOrganisationMutationBody = OrganisationPatchBodyBody\n export type PatchOrganisationMutationError = ErrorType<AsError>\n\n /**\n * @summary Adjust an existing Organisation\n */\nexport const usePatchOrganisation = <TError = ErrorType<AsError>,\n TContext = unknown>(options?: { mutation?:UseMutationOptions<Awaited<ReturnType<typeof patchOrganisation>>, TError,{orgId: string;data: OrganisationPatchBodyBody}, TContext>, request?: SecondParameter<typeof customInstance>}\n) => {\n\n const mutationOptions = getPatchOrganisationMutationOptions(options);\n\n return useMutation(mutationOptions);\n }\n /**\n * Before an Organisation can be deleted all its underlying **Units** must also be deleted, remembering that **Units** that have undeleted **Products** cannot be deleted.\n\nYou need admin rights to use this method\n\n * @summary Deletes an Organisation\n */\nexport const deleteOrganisation = (\n orgId: string,\n options?: SecondParameter<typeof customInstance>,) => {\n \n \n return customInstance<void>(\n {url: `/organisation/${orgId}`, method: 'DELETE'\n },\n options);\n }\n \n\n\nexport const getDeleteOrganisationMutationOptions = <TError = ErrorType<AsError>,\n TContext = unknown>(options?: { mutation?:UseMutationOptions<Awaited<ReturnType<typeof deleteOrganisation>>, TError,{orgId: string}, TContext>, request?: SecondParameter<typeof customInstance>}\n): UseMutationOptions<Awaited<ReturnType<typeof deleteOrganisation>>, TError,{orgId: string}, TContext> => {\n const {mutation: mutationOptions, request: requestOptions} = options ?? {};\n\n \n\n\n const mutationFn: MutationFunction<Awaited<ReturnType<typeof deleteOrganisation>>, {orgId: string}> = (props) => {\n const {orgId} = props ?? {};\n\n return deleteOrganisation(orgId,requestOptions)\n }\n\n \n\n\n return { mutationFn, ...mutationOptions }}\n\n export type DeleteOrganisationMutationResult = NonNullable<Awaited<ReturnType<typeof deleteOrganisation>>>\n \n export type DeleteOrganisationMutationError = ErrorType<AsError>\n\n /**\n * @summary Deletes an Organisation\n */\nexport const useDeleteOrganisation = <TError = ErrorType<AsError>,\n TContext = unknown>(options?: { mutation?:UseMutationOptions<Awaited<ReturnType<typeof deleteOrganisation>>, TError,{orgId: string}, TContext>, request?: SecondParameter<typeof customInstance>}\n) => {\n\n const mutationOptions = getDeleteOrganisationMutationOptions(options);\n\n return useMutation(mutationOptions);\n }\n /**\n * Gets the Default Organisation, a built-in Organisation used exclusively for **Personal Units**.\n\nAny authorised user can see the Default Organisation.\n\n * @summary Gets the Default Organisation\n */\nexport const getDefaultOrganisation = (\n \n options?: SecondParameter<typeof customInstance>,signal?: AbortSignal\n) => {\n \n \n return customInstance<OrganisationGetDefaultResponse>(\n {url: `/organisation/default`, method: 'GET', signal\n },\n options);\n }\n \n\nexport const getGetDefaultOrganisationQueryKey = () => {\n return [\"account-server-api\", `/organisation/default`] as const;\n }\n\n \nexport const getGetDefaultOrganisationQueryOptions = <TData = Awaited<ReturnType<typeof getDefaultOrganisation>>, TError = ErrorType<void | AsError>>( options?: { query?:Partial<UseQueryOptions<Awaited<ReturnType<typeof getDefaultOrganisation>>, TError, TData>>, request?: SecondParameter<typeof customInstance>}\n) => {\n\nconst {query: queryOptions, request: requestOptions} = options ?? {};\n\n const queryKey = queryOptions?.queryKey ?? getGetDefaultOrganisationQueryKey();\n\n \n\n const queryFn: QueryFunction<Awaited<ReturnType<typeof getDefaultOrganisation>>> = ({ signal }) => getDefaultOrganisation(requestOptions, signal);\n\n \n\n \n\n return { queryKey, queryFn, ...queryOptions} as UseQueryOptions<Awaited<ReturnType<typeof getDefaultOrganisation>>, TError, TData> & { queryKey: QueryKey }\n}\n\nexport type GetDefaultOrganisationQueryResult = NonNullable<Awaited<ReturnType<typeof getDefaultOrganisation>>>\nexport type GetDefaultOrganisationQueryError = ErrorType<void | AsError>\n\n/**\n * @summary Gets the Default Organisation\n */\nexport const useGetDefaultOrganisation = <TData = Awaited<ReturnType<typeof getDefaultOrganisation>>, TError = ErrorType<void | AsError>>(\n options?: { query?:Partial<UseQueryOptions<Awaited<ReturnType<typeof getDefaultOrganisation>>, TError, TData>>, request?: SecondParameter<typeof customInstance>}\n\n ): UseQueryResult<TData, TError> & { queryKey: QueryKey } => {\n\n const queryOptions = getGetDefaultOrganisationQueryOptions(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\nexport const getGetDefaultOrganisationSuspenseQueryOptions = <TData = Awaited<ReturnType<typeof getDefaultOrganisation>>, TError = ErrorType<void | AsError>>( options?: { query?:Partial<UseSuspenseQueryOptions<Awaited<ReturnType<typeof getDefaultOrganisation>>, TError, TData>>, request?: SecondParameter<typeof customInstance>}\n) => {\n\nconst {query: queryOptions, request: requestOptions} = options ?? {};\n\n const queryKey = queryOptions?.queryKey ?? getGetDefaultOrganisationQueryKey();\n\n \n\n const queryFn: QueryFunction<Awaited<ReturnType<typeof getDefaultOrganisation>>> = ({ signal }) => getDefaultOrganisation(requestOptions, signal);\n\n \n\n \n\n return { queryKey, queryFn, ...queryOptions} as UseSuspenseQueryOptions<Awaited<ReturnType<typeof getDefaultOrganisation>>, TError, TData> & { queryKey: QueryKey }\n}\n\nexport type GetDefaultOrganisationSuspenseQueryResult = NonNullable<Awaited<ReturnType<typeof getDefaultOrganisation>>>\nexport type GetDefaultOrganisationSuspenseQueryError = ErrorType<void | AsError>\n\n/**\n * @summary Gets the Default Organisation\n */\nexport const useGetDefaultOrganisationSuspense = <TData = Awaited<ReturnType<typeof getDefaultOrganisation>>, TError = ErrorType<void | AsError>>(\n options?: { query?:Partial<UseSuspenseQueryOptions<Awaited<ReturnType<typeof getDefaultOrganisation>>, TError, TData>>, request?: SecondParameter<typeof customInstance>}\n\n ): UseSuspenseQueryResult<TData, TError> & { queryKey: QueryKey } => {\n\n const queryOptions = getGetDefaultOrganisationSuspenseQueryOptions(options)\n\n const query = useSuspenseQuery(queryOptions) as UseSuspenseQueryResult<TData, TError> & { queryKey: QueryKey };\n\n query.queryKey = queryOptions.queryKey ;\n\n return query;\n}\n\n\n\n"]}
@@ -1,6 +1,6 @@
1
1
  import * as _tanstack_react_query_build_legacy_types from '@tanstack/react-query/build/legacy/types';
2
2
  import { UseQueryOptions, QueryKey, UseQueryResult, UseSuspenseQueryOptions, UseSuspenseQueryResult, UseMutationOptions } from '@tanstack/react-query';
3
- import { customInstance, OrganisationsGetResponse, ErrorType, AsError, OrganisationPostBodyBody, OrganisationPostResponse, OrganisationAllDetail, OrganisationPatchBodyBody, GetOrganisationChargesParams, OrganisationChargesGetResponse, OrganisationGetDefaultResponse } from '../index.cjs';
3
+ import { customInstance, OrganisationsGetResponse, ErrorType, AsError, OrganisationPostBodyBody, OrganisationPostResponse, OrganisationAllDetail, OrganisationPatchBodyBody, OrganisationGetDefaultResponse } from '../index.cjs';
4
4
  import 'axios';
5
5
 
6
6
  type SecondParameter<T extends (...args: any) => any> = Parameters<T>[1];
@@ -186,55 +186,12 @@ declare const useDeleteOrganisation: <TError = ErrorType<AsError>, TContext = un
186
186
  orgId: string;
187
187
  }, TContext>;
188
188
  /**
189
- * Gets a Organisation charges.
190
-
191
- The Organisation cannot be the **Default Organisation** and you need to be a member of the Organisation to use this endpoint
192
-
193
- * @summary Gets charges for all Units in an Organisation
194
- */
195
- declare const getOrganisationCharges: (orgId: string, params?: GetOrganisationChargesParams, options?: SecondParameter<typeof customInstance>, signal?: AbortSignal) => Promise<OrganisationChargesGetResponse>;
196
- declare const getGetOrganisationChargesQueryKey: (orgId: string, params?: GetOrganisationChargesParams) => readonly ["account-server-api", `/organisation/${string}/charges`, ...GetOrganisationChargesParams[]];
197
- declare const getGetOrganisationChargesQueryOptions: <TData = OrganisationChargesGetResponse, TError = ErrorType<void | AsError>>(orgId: string, params?: GetOrganisationChargesParams, options?: {
198
- query?: Partial<UseQueryOptions<OrganisationChargesGetResponse, TError, TData, QueryKey>> | undefined;
199
- request?: SecondParameter<typeof customInstance>;
200
- } | undefined) => UseQueryOptions<OrganisationChargesGetResponse, TError, TData, QueryKey> & {
201
- queryKey: QueryKey;
202
- };
203
- type GetOrganisationChargesQueryResult = NonNullable<Awaited<ReturnType<typeof getOrganisationCharges>>>;
204
- type GetOrganisationChargesQueryError = ErrorType<void | AsError>;
205
- /**
206
- * @summary Gets charges for all Units in an Organisation
207
- */
208
- declare const useGetOrganisationCharges: <TData = OrganisationChargesGetResponse, TError = ErrorType<void | AsError>>(orgId: string, params?: GetOrganisationChargesParams, options?: {
209
- query?: Partial<UseQueryOptions<OrganisationChargesGetResponse, TError, TData, QueryKey>> | undefined;
210
- request?: SecondParameter<typeof customInstance>;
211
- } | undefined) => UseQueryResult<TData, TError> & {
212
- queryKey: QueryKey;
213
- };
214
- declare const getGetOrganisationChargesSuspenseQueryOptions: <TData = OrganisationChargesGetResponse, TError = ErrorType<void | AsError>>(orgId: string, params?: GetOrganisationChargesParams, options?: {
215
- query?: Partial<UseSuspenseQueryOptions<OrganisationChargesGetResponse, TError, TData, QueryKey>> | undefined;
216
- request?: SecondParameter<typeof customInstance>;
217
- } | undefined) => UseSuspenseQueryOptions<OrganisationChargesGetResponse, TError, TData, QueryKey> & {
218
- queryKey: QueryKey;
219
- };
220
- type GetOrganisationChargesSuspenseQueryResult = NonNullable<Awaited<ReturnType<typeof getOrganisationCharges>>>;
221
- type GetOrganisationChargesSuspenseQueryError = ErrorType<void | AsError>;
222
- /**
223
- * @summary Gets charges for all Units in an Organisation
224
- */
225
- declare const useGetOrganisationChargesSuspense: <TData = OrganisationChargesGetResponse, TError = ErrorType<void | AsError>>(orgId: string, params?: GetOrganisationChargesParams, options?: {
226
- query?: Partial<UseSuspenseQueryOptions<OrganisationChargesGetResponse, TError, TData, QueryKey>> | undefined;
227
- request?: SecondParameter<typeof customInstance>;
228
- } | undefined) => UseSuspenseQueryResult<TData, TError> & {
229
- queryKey: QueryKey;
230
- };
231
- /**
232
- * Gets the Default Organisation, a built-in Organisation used exclusively for **Personal Units**.
189
+ * Gets the Default Organisation, a built-in Organisation used exclusively for **Personal Units**.
233
190
 
234
191
  Any authorised user can see the Default Organisation.
235
192
 
236
- * @summary Gets the Default Organisation
237
- */
193
+ * @summary Gets the Default Organisation
194
+ */
238
195
  declare const getDefaultOrganisation: (options?: SecondParameter<typeof customInstance>, signal?: AbortSignal) => Promise<OrganisationGetDefaultResponse>;
239
196
  declare const getGetDefaultOrganisationQueryKey: () => readonly ["account-server-api", "/organisation/default"];
240
197
  declare const getGetDefaultOrganisationQueryOptions: <TData = OrganisationGetDefaultResponse, TError = ErrorType<void | AsError>>(options?: {
@@ -272,4 +229,4 @@ declare const useGetDefaultOrganisationSuspense: <TData = OrganisationGetDefault
272
229
  queryKey: QueryKey;
273
230
  };
274
231
 
275
- export { type CreateOrganisationMutationBody, type CreateOrganisationMutationError, type CreateOrganisationMutationResult, type DeleteOrganisationMutationError, type DeleteOrganisationMutationResult, type GetDefaultOrganisationQueryError, type GetDefaultOrganisationQueryResult, type GetDefaultOrganisationSuspenseQueryError, type GetDefaultOrganisationSuspenseQueryResult, type GetOrganisationChargesQueryError, type GetOrganisationChargesQueryResult, type GetOrganisationChargesSuspenseQueryError, type GetOrganisationChargesSuspenseQueryResult, type GetOrganisationQueryError, type GetOrganisationQueryResult, type GetOrganisationSuspenseQueryError, type GetOrganisationSuspenseQueryResult, type GetOrganisationsQueryError, type GetOrganisationsQueryResult, type GetOrganisationsSuspenseQueryError, type GetOrganisationsSuspenseQueryResult, type PatchOrganisationMutationBody, type PatchOrganisationMutationError, type PatchOrganisationMutationResult, createOrganisation, deleteOrganisation, getCreateOrganisationMutationOptions, getDefaultOrganisation, getDeleteOrganisationMutationOptions, getGetDefaultOrganisationQueryKey, getGetDefaultOrganisationQueryOptions, getGetDefaultOrganisationSuspenseQueryOptions, getGetOrganisationChargesQueryKey, getGetOrganisationChargesQueryOptions, getGetOrganisationChargesSuspenseQueryOptions, getGetOrganisationQueryKey, getGetOrganisationQueryOptions, getGetOrganisationSuspenseQueryOptions, getGetOrganisationsQueryKey, getGetOrganisationsQueryOptions, getGetOrganisationsSuspenseQueryOptions, getOrganisation, getOrganisationCharges, getOrganisations, getPatchOrganisationMutationOptions, patchOrganisation, useCreateOrganisation, useDeleteOrganisation, useGetDefaultOrganisation, useGetDefaultOrganisationSuspense, useGetOrganisation, useGetOrganisationCharges, useGetOrganisationChargesSuspense, useGetOrganisationSuspense, useGetOrganisations, useGetOrganisationsSuspense, usePatchOrganisation };
232
+ export { type CreateOrganisationMutationBody, type CreateOrganisationMutationError, type CreateOrganisationMutationResult, type DeleteOrganisationMutationError, type DeleteOrganisationMutationResult, type GetDefaultOrganisationQueryError, type GetDefaultOrganisationQueryResult, type GetDefaultOrganisationSuspenseQueryError, type GetDefaultOrganisationSuspenseQueryResult, type GetOrganisationQueryError, type GetOrganisationQueryResult, type GetOrganisationSuspenseQueryError, type GetOrganisationSuspenseQueryResult, type GetOrganisationsQueryError, type GetOrganisationsQueryResult, type GetOrganisationsSuspenseQueryError, type GetOrganisationsSuspenseQueryResult, type PatchOrganisationMutationBody, type PatchOrganisationMutationError, type PatchOrganisationMutationResult, createOrganisation, deleteOrganisation, getCreateOrganisationMutationOptions, getDefaultOrganisation, getDeleteOrganisationMutationOptions, getGetDefaultOrganisationQueryKey, getGetDefaultOrganisationQueryOptions, getGetDefaultOrganisationSuspenseQueryOptions, getGetOrganisationQueryKey, getGetOrganisationQueryOptions, getGetOrganisationSuspenseQueryOptions, getGetOrganisationsQueryKey, getGetOrganisationsQueryOptions, getGetOrganisationsSuspenseQueryOptions, getOrganisation, getOrganisations, getPatchOrganisationMutationOptions, patchOrganisation, useCreateOrganisation, useDeleteOrganisation, useGetDefaultOrganisation, useGetDefaultOrganisationSuspense, useGetOrganisation, useGetOrganisationSuspense, useGetOrganisations, useGetOrganisationsSuspense, usePatchOrganisation };
@@ -1,6 +1,6 @@
1
1
  import * as _tanstack_react_query_build_legacy_types from '@tanstack/react-query/build/legacy/types';
2
2
  import { UseQueryOptions, QueryKey, UseQueryResult, UseSuspenseQueryOptions, UseSuspenseQueryResult, UseMutationOptions } from '@tanstack/react-query';
3
- import { customInstance, OrganisationsGetResponse, ErrorType, AsError, OrganisationPostBodyBody, OrganisationPostResponse, OrganisationAllDetail, OrganisationPatchBodyBody, GetOrganisationChargesParams, OrganisationChargesGetResponse, OrganisationGetDefaultResponse } from '../index.js';
3
+ import { customInstance, OrganisationsGetResponse, ErrorType, AsError, OrganisationPostBodyBody, OrganisationPostResponse, OrganisationAllDetail, OrganisationPatchBodyBody, OrganisationGetDefaultResponse } from '../index.js';
4
4
  import 'axios';
5
5
 
6
6
  type SecondParameter<T extends (...args: any) => any> = Parameters<T>[1];
@@ -186,55 +186,12 @@ declare const useDeleteOrganisation: <TError = ErrorType<AsError>, TContext = un
186
186
  orgId: string;
187
187
  }, TContext>;
188
188
  /**
189
- * Gets a Organisation charges.
190
-
191
- The Organisation cannot be the **Default Organisation** and you need to be a member of the Organisation to use this endpoint
192
-
193
- * @summary Gets charges for all Units in an Organisation
194
- */
195
- declare const getOrganisationCharges: (orgId: string, params?: GetOrganisationChargesParams, options?: SecondParameter<typeof customInstance>, signal?: AbortSignal) => Promise<OrganisationChargesGetResponse>;
196
- declare const getGetOrganisationChargesQueryKey: (orgId: string, params?: GetOrganisationChargesParams) => readonly ["account-server-api", `/organisation/${string}/charges`, ...GetOrganisationChargesParams[]];
197
- declare const getGetOrganisationChargesQueryOptions: <TData = OrganisationChargesGetResponse, TError = ErrorType<void | AsError>>(orgId: string, params?: GetOrganisationChargesParams, options?: {
198
- query?: Partial<UseQueryOptions<OrganisationChargesGetResponse, TError, TData, QueryKey>> | undefined;
199
- request?: SecondParameter<typeof customInstance>;
200
- } | undefined) => UseQueryOptions<OrganisationChargesGetResponse, TError, TData, QueryKey> & {
201
- queryKey: QueryKey;
202
- };
203
- type GetOrganisationChargesQueryResult = NonNullable<Awaited<ReturnType<typeof getOrganisationCharges>>>;
204
- type GetOrganisationChargesQueryError = ErrorType<void | AsError>;
205
- /**
206
- * @summary Gets charges for all Units in an Organisation
207
- */
208
- declare const useGetOrganisationCharges: <TData = OrganisationChargesGetResponse, TError = ErrorType<void | AsError>>(orgId: string, params?: GetOrganisationChargesParams, options?: {
209
- query?: Partial<UseQueryOptions<OrganisationChargesGetResponse, TError, TData, QueryKey>> | undefined;
210
- request?: SecondParameter<typeof customInstance>;
211
- } | undefined) => UseQueryResult<TData, TError> & {
212
- queryKey: QueryKey;
213
- };
214
- declare const getGetOrganisationChargesSuspenseQueryOptions: <TData = OrganisationChargesGetResponse, TError = ErrorType<void | AsError>>(orgId: string, params?: GetOrganisationChargesParams, options?: {
215
- query?: Partial<UseSuspenseQueryOptions<OrganisationChargesGetResponse, TError, TData, QueryKey>> | undefined;
216
- request?: SecondParameter<typeof customInstance>;
217
- } | undefined) => UseSuspenseQueryOptions<OrganisationChargesGetResponse, TError, TData, QueryKey> & {
218
- queryKey: QueryKey;
219
- };
220
- type GetOrganisationChargesSuspenseQueryResult = NonNullable<Awaited<ReturnType<typeof getOrganisationCharges>>>;
221
- type GetOrganisationChargesSuspenseQueryError = ErrorType<void | AsError>;
222
- /**
223
- * @summary Gets charges for all Units in an Organisation
224
- */
225
- declare const useGetOrganisationChargesSuspense: <TData = OrganisationChargesGetResponse, TError = ErrorType<void | AsError>>(orgId: string, params?: GetOrganisationChargesParams, options?: {
226
- query?: Partial<UseSuspenseQueryOptions<OrganisationChargesGetResponse, TError, TData, QueryKey>> | undefined;
227
- request?: SecondParameter<typeof customInstance>;
228
- } | undefined) => UseSuspenseQueryResult<TData, TError> & {
229
- queryKey: QueryKey;
230
- };
231
- /**
232
- * Gets the Default Organisation, a built-in Organisation used exclusively for **Personal Units**.
189
+ * Gets the Default Organisation, a built-in Organisation used exclusively for **Personal Units**.
233
190
 
234
191
  Any authorised user can see the Default Organisation.
235
192
 
236
- * @summary Gets the Default Organisation
237
- */
193
+ * @summary Gets the Default Organisation
194
+ */
238
195
  declare const getDefaultOrganisation: (options?: SecondParameter<typeof customInstance>, signal?: AbortSignal) => Promise<OrganisationGetDefaultResponse>;
239
196
  declare const getGetDefaultOrganisationQueryKey: () => readonly ["account-server-api", "/organisation/default"];
240
197
  declare const getGetDefaultOrganisationQueryOptions: <TData = OrganisationGetDefaultResponse, TError = ErrorType<void | AsError>>(options?: {
@@ -272,4 +229,4 @@ declare const useGetDefaultOrganisationSuspense: <TData = OrganisationGetDefault
272
229
  queryKey: QueryKey;
273
230
  };
274
231
 
275
- export { type CreateOrganisationMutationBody, type CreateOrganisationMutationError, type CreateOrganisationMutationResult, type DeleteOrganisationMutationError, type DeleteOrganisationMutationResult, type GetDefaultOrganisationQueryError, type GetDefaultOrganisationQueryResult, type GetDefaultOrganisationSuspenseQueryError, type GetDefaultOrganisationSuspenseQueryResult, type GetOrganisationChargesQueryError, type GetOrganisationChargesQueryResult, type GetOrganisationChargesSuspenseQueryError, type GetOrganisationChargesSuspenseQueryResult, type GetOrganisationQueryError, type GetOrganisationQueryResult, type GetOrganisationSuspenseQueryError, type GetOrganisationSuspenseQueryResult, type GetOrganisationsQueryError, type GetOrganisationsQueryResult, type GetOrganisationsSuspenseQueryError, type GetOrganisationsSuspenseQueryResult, type PatchOrganisationMutationBody, type PatchOrganisationMutationError, type PatchOrganisationMutationResult, createOrganisation, deleteOrganisation, getCreateOrganisationMutationOptions, getDefaultOrganisation, getDeleteOrganisationMutationOptions, getGetDefaultOrganisationQueryKey, getGetDefaultOrganisationQueryOptions, getGetDefaultOrganisationSuspenseQueryOptions, getGetOrganisationChargesQueryKey, getGetOrganisationChargesQueryOptions, getGetOrganisationChargesSuspenseQueryOptions, getGetOrganisationQueryKey, getGetOrganisationQueryOptions, getGetOrganisationSuspenseQueryOptions, getGetOrganisationsQueryKey, getGetOrganisationsQueryOptions, getGetOrganisationsSuspenseQueryOptions, getOrganisation, getOrganisationCharges, getOrganisations, getPatchOrganisationMutationOptions, patchOrganisation, useCreateOrganisation, useDeleteOrganisation, useGetDefaultOrganisation, useGetDefaultOrganisationSuspense, useGetOrganisation, useGetOrganisationCharges, useGetOrganisationChargesSuspense, useGetOrganisationSuspense, useGetOrganisations, useGetOrganisationsSuspense, usePatchOrganisation };
232
+ export { type CreateOrganisationMutationBody, type CreateOrganisationMutationError, type CreateOrganisationMutationResult, type DeleteOrganisationMutationError, type DeleteOrganisationMutationResult, type GetDefaultOrganisationQueryError, type GetDefaultOrganisationQueryResult, type GetDefaultOrganisationSuspenseQueryError, type GetDefaultOrganisationSuspenseQueryResult, type GetOrganisationQueryError, type GetOrganisationQueryResult, type GetOrganisationSuspenseQueryError, type GetOrganisationSuspenseQueryResult, type GetOrganisationsQueryError, type GetOrganisationsQueryResult, type GetOrganisationsSuspenseQueryError, type GetOrganisationsSuspenseQueryResult, type PatchOrganisationMutationBody, type PatchOrganisationMutationError, type PatchOrganisationMutationResult, createOrganisation, deleteOrganisation, getCreateOrganisationMutationOptions, getDefaultOrganisation, getDeleteOrganisationMutationOptions, getGetDefaultOrganisationQueryKey, getGetDefaultOrganisationQueryOptions, getGetDefaultOrganisationSuspenseQueryOptions, getGetOrganisationQueryKey, getGetOrganisationQueryOptions, getGetOrganisationSuspenseQueryOptions, getGetOrganisationsQueryKey, getGetOrganisationsQueryOptions, getGetOrganisationsSuspenseQueryOptions, getOrganisation, getOrganisations, getPatchOrganisationMutationOptions, patchOrganisation, useCreateOrganisation, useDeleteOrganisation, useGetDefaultOrganisation, useGetDefaultOrganisationSuspense, useGetOrganisation, useGetOrganisationSuspense, useGetOrganisations, useGetOrganisationsSuspense, usePatchOrganisation };