@hyperline/cli 0.1.0-build.1.7046368 → 0.1.0-build.1.724f81a

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.
@@ -34894,10 +34894,10 @@ var require_shared = __commonJS({
34894
34894
  ZodId: () => ZodId,
34895
34895
  ZodTranslationsSchemaFn: () => ZodTranslationsSchemaFn
34896
34896
  });
34897
- var import_zod17 = require_lib();
34897
+ var import_zod19 = require_lib();
34898
34898
  var countryIds2 = ["all", ...countries.map(({ id }) => id)];
34899
- var ZodId = import_zod17.z.enum(countryIds2);
34900
- var ZodTranslationsSchemaFn = (schema) => import_zod17.z.record(import_zod17.z.string(), schema.optional());
34899
+ var ZodId = import_zod19.z.enum(countryIds2);
34900
+ var ZodTranslationsSchemaFn = (schema) => import_zod19.z.record(import_zod19.z.string(), schema.optional());
34901
34901
  var UsStates = [
34902
34902
  { id: "AA", name: "Armed Forces Americas" },
34903
34903
  { id: "AE", name: "Armed Forces Europe" },
@@ -37934,7 +37934,7 @@ Examples:
37934
37934
  queryParamKeys: ["take", "skip"]
37935
37935
  });
37936
37936
  });
37937
- resource.command("get").description(`Retrieve a specific bank account by its ID. Returns bank account details including IBAN, BIC, and currency.`).requiredOption("--id <value>", `id parameter`).addHelpText("after", `
37937
+ resource.command("get").description(`Retrieve a specific bank account by its ID. Returns masked bank account details, account type, balance, and currency.`).requiredOption("--id <value>", `id parameter`).addHelpText("after", `
37938
37938
  Examples:
37939
37939
  hyperline bank-accounts get --id <id>`).action(async (opts) => {
37940
37940
  const ctx = resource.parent?.opts()._ctx;
@@ -37952,6 +37952,31 @@ Examples:
37952
37952
  queryParamKeys: []
37953
37953
  });
37954
37954
  });
37955
+ resource.command("list-bank-account-transactions").description(`List open banking transactions for a specific bank account. Paginated with limit/cursor.`).requiredOption("--id <value>", `id parameter`).option("--limit <number>", `Maximum number of items to return (1-100).`).option("--cursor <value>", `Opaque cursor returned in the previous response's \`next_cursor\`. Omit to fetch the first page.`).option("--include-total <value>", `Set to \`true\` to include \`total\` in the response.`).addHelpText("after", `
37956
+ Examples:
37957
+ hyperline bank-accounts list-bank-account-transactions --id <id>
37958
+ hyperline bank-accounts list-bank-account-transactions --id <id> --limit <limit> --cursor <cursor>`).action(async (opts) => {
37959
+ const ctx = resource.parent?.opts()._ctx;
37960
+ if (!ctx) {
37961
+ process.stderr.write("Error: Not authenticated\n");
37962
+ process.exit(1);
37963
+ }
37964
+ const args = {};
37965
+ if (opts.id !== void 0)
37966
+ args.id = opts.id;
37967
+ if (opts.cursor !== void 0)
37968
+ args.cursor = opts.cursor;
37969
+ if (opts.includeTotal !== void 0)
37970
+ args.include_total = opts.includeTotal;
37971
+ if (opts.limit !== void 0)
37972
+ args.limit = Number(opts.limit);
37973
+ await ctx.execute({
37974
+ method: "GET",
37975
+ path: "/v1/bank-accounts/{id}/transactions",
37976
+ args,
37977
+ queryParamKeys: ["limit", "cursor", "include_total"]
37978
+ });
37979
+ });
37955
37980
  }
37956
37981
 
37957
37982
  // build/commands/generated/companies.js
@@ -38020,7 +38045,7 @@ Examples:
38020
38045
  queryParamKeys: ["take", "skip"]
38021
38046
  });
38022
38047
  });
38023
- resource.command("create").description(`Create a new coupon with discount rules. Supports percentage or fixed amount discounts, duration limits, and redemption restrictions.`).requiredOption("--name <value>", `Coupon name.`).option("--description <value>", `Coupon description.`).option("--expiration-date <value>", `Date corresponding to the expiration of the coupon.`).option("--redemption-limit <number>", `Maximum number of subscriptions to which a single coupon can be applied.`).option("--product-ids <value>", `List of product IDs the coupon can be applied to. If empty, the coupon can be applied to any product.`).requiredOption("--type <value>", `type`).option("--discount-amount <number>", `Amount to apply as a discount on the total amount (excluding taxes) of a subscription. Expressed in the currency's smallest unit.`).option("--currency <value>", `Currency code. See [ISO 4217](https://en.wikipedia.org/wiki/ISO_4217#List_of_ISO_4217_currency_codes).`).option("--discount-percent <number>", `Percentage to apply as a discount on the amount (excluding taxes) of a product.`).addHelpText("after", `
38048
+ resource.command("create").description(`Create a new coupon with discount rules. Supports percentage or fixed amount discounts, duration limits, and redemption restrictions.`).requiredOption("--name <value>", `Coupon name.`).option("--description <value>", `Coupon description.`).option("--expiration-date <value>", `Date corresponding to the expiration of the coupon.`).option("--redemption-limit <number>", `Maximum number of subscriptions to which a single coupon can be applied.`).option("--product-ids <value>", `List of product IDs the coupon can be applied to. If empty, the coupon can be applied to any product.`).option("--repeat <value>", `Default repeat behaviour applied when the coupon is attached to a subscription. Valid values: \`once\`, \`forever\`, \`duration\`. Can be overridden at attach time.`).option("--duration <value>", `Default duration applied when \`repeat\` is \`duration\`. Required when \`repeat\` is \`duration\`, must be null otherwise.`).requiredOption("--type <value>", `type`).option("--discount-amount <number>", `Amount to apply as a discount on the total amount (excluding taxes) of a subscription. Expressed in the currency's smallest unit.`).option("--currency <value>", `Currency code. See [ISO 4217](https://en.wikipedia.org/wiki/ISO_4217#List_of_ISO_4217_currency_codes).`).option("--discount-percent <number>", `Percentage to apply as a discount on the amount (excluding taxes) of a product.`).addHelpText("after", `
38024
38049
  Examples:
38025
38050
  hyperline coupons create --name <name> --type <type>
38026
38051
  hyperline coupons create --name <name> --type <type> --description <description> --expiration-date <expiration_date>
@@ -38039,6 +38064,10 @@ Examples:
38039
38064
  args.expiration_date = opts.expirationDate;
38040
38065
  if (opts.productIds !== void 0)
38041
38066
  args.product_ids = opts.productIds;
38067
+ if (opts.repeat !== void 0)
38068
+ args.repeat = opts.repeat;
38069
+ if (opts.duration !== void 0)
38070
+ args.duration = opts.duration;
38042
38071
  if (opts.type !== void 0)
38043
38072
  args.type = opts.type;
38044
38073
  if (opts.currency !== void 0)
@@ -38074,7 +38103,7 @@ Examples:
38074
38103
  queryParamKeys: []
38075
38104
  });
38076
38105
  });
38077
- resource.command("update").description(`Update an existing coupon's name, discount rules, or restrictions.`).requiredOption("--id <value>", `id parameter`).requiredOption("--name <value>", `Coupon name.`).option("--description <value>", `Coupon description.`).option("--expiration-date <value>", `Date corresponding to the expiration of the coupon.`).option("--redemption-limit <number>", `Maximum number of subscriptions to which a single coupon can be applied.`).option("--product-ids <value>", `List of product IDs the coupon can be applied to. If empty, the coupon can be applied to any product.`).requiredOption("--type <value>", `type`).option("--discount-amount <number>", `Amount to apply as a discount on the total amount (excluding taxes) of a subscription. Expressed in the currency's smallest unit.`).option("--currency <value>", `Currency code. See [ISO 4217](https://en.wikipedia.org/wiki/ISO_4217#List_of_ISO_4217_currency_codes).`).option("--discount-percent <number>", `Percentage to apply as a discount on the amount (excluding taxes) of a product.`).addHelpText("after", `
38106
+ resource.command("update").description(`Update an existing coupon's name, discount rules, or restrictions.`).requiredOption("--id <value>", `id parameter`).requiredOption("--name <value>", `Coupon name.`).option("--description <value>", `Coupon description.`).option("--expiration-date <value>", `Date corresponding to the expiration of the coupon.`).option("--redemption-limit <number>", `Maximum number of subscriptions to which a single coupon can be applied.`).option("--product-ids <value>", `List of product IDs the coupon can be applied to. If empty, the coupon can be applied to any product.`).option("--repeat <value>", `Default repeat behaviour applied when the coupon is attached to a subscription. Valid values: \`once\`, \`forever\`, \`duration\`. Can be overridden at attach time.`).option("--duration <value>", `Default duration applied when \`repeat\` is \`duration\`. Required when \`repeat\` is \`duration\`, must be null otherwise.`).requiredOption("--type <value>", `type`).option("--discount-amount <number>", `Amount to apply as a discount on the total amount (excluding taxes) of a subscription. Expressed in the currency's smallest unit.`).option("--currency <value>", `Currency code. See [ISO 4217](https://en.wikipedia.org/wiki/ISO_4217#List_of_ISO_4217_currency_codes).`).option("--discount-percent <number>", `Percentage to apply as a discount on the amount (excluding taxes) of a product.`).addHelpText("after", `
38078
38107
  Examples:
38079
38108
  hyperline coupons update --id <id> --name <name> --type <type>
38080
38109
  hyperline coupons update --id <id> --name <name> --type <type> --description <description> --expiration-date <expiration_date>
@@ -38095,6 +38124,10 @@ Examples:
38095
38124
  args.expiration_date = opts.expirationDate;
38096
38125
  if (opts.productIds !== void 0)
38097
38126
  args.product_ids = opts.productIds;
38127
+ if (opts.repeat !== void 0)
38128
+ args.repeat = opts.repeat;
38129
+ if (opts.duration !== void 0)
38130
+ args.duration = opts.duration;
38098
38131
  if (opts.type !== void 0)
38099
38132
  args.type = opts.type;
38100
38133
  if (opts.currency !== void 0)
@@ -38429,16 +38462,24 @@ Examples:
38429
38462
  // build/commands/generated/customers.js
38430
38463
  function registerCustomersCommands(parent) {
38431
38464
  const resource = parent.command("customers").description("Manage customers");
38432
- resource.command("list").description(`List customers with optional filters for name, type, status, currency, country, external_id, billing_email, search, tax_id, subscription_status, invoicing_entity_id, segment_id, custom_properties, payment_method_type, created_at, updated_at. Paginated with take/skip.`).option("--take <number>", `take`).option("--skip <number>", `skip`).option("--name <value>", `name`).option("--name.not <value>", `name__not`).option("--name.is-null <value>", `name__isNull`).option("--name.is-not-null <value>", `name__isNotNull`).option("--name.equals <value>", `name__equals`).option("--name.contains <value>", `name__contains`).option("--name.starts-with <value>", `name__startsWith`).option("--name.end-with <value>", `name__endWith`).option("--type <value>", `type`).option("--type.in <value>", `type__in`).option("--status <value>", `status`).option("--status.in <value>", `status__in`).option("--currency <value>", `currency`).option("--currency.not <value>", `currency__not`).option("--currency.is-null <value>", `currency__isNull`).option("--currency.is-not-null <value>", `currency__isNotNull`).option("--currency.equals <value>", `currency__equals`).option("--currency.contains <value>", `currency__contains`).option("--currency.starts-with <value>", `currency__startsWith`).option("--currency.end-with <value>", `currency__endWith`).option("--country <value>", `country`).option("--country.not <value>", `country__not`).option("--country.is-null <value>", `country__isNull`).option("--country.is-not-null <value>", `country__isNotNull`).option("--country.equals <value>", `country__equals`).option("--country.contains <value>", `country__contains`).option("--country.starts-with <value>", `country__startsWith`).option("--country.end-with <value>", `country__endWith`).option("--external-id <value>", `external_id`).option("--external-id.not <value>", `external_id__not`).option("--external-id.is-null <value>", `external_id__isNull`).option("--external-id.is-not-null <value>", `external_id__isNotNull`).option("--external-id.equals <value>", `external_id__equals`).option("--external-id.contains <value>", `external_id__contains`).option("--external-id.starts-with <value>", `external_id__startsWith`).option("--external-id.end-with <value>", `external_id__endWith`).option("--billing-email <value>", `billing_email`).option("--billing-email.not <value>", `billing_email__not`).option("--billing-email.is-null <value>", `billing_email__isNull`).option("--billing-email.is-not-null <value>", `billing_email__isNotNull`).option("--billing-email.equals <value>", `billing_email__equals`).option("--billing-email.contains <value>", `billing_email__contains`).option("--billing-email.starts-with <value>", `billing_email__startsWith`).option("--billing-email.end-with <value>", `billing_email__endWith`).option("--search <value>", `search`).option("--tax-id <value>", `tax_id`).option("--tax-id.not <value>", `tax_id__not`).option("--tax-id.is-null <value>", `tax_id__isNull`).option("--tax-id.is-not-null <value>", `tax_id__isNotNull`).option("--tax-id.equals <value>", `tax_id__equals`).option("--tax-id.contains <value>", `tax_id__contains`).option("--tax-id.starts-with <value>", `tax_id__startsWith`).option("--tax-id.end-with <value>", `tax_id__endWith`).option("--subscription-status <value>", `subscription_status`).option("--subscription-status.in <value>", `subscription_status__in`).option("--invoicing-entity-id <value>", `invoicing_entity_id`).option("--invoicing-entity-id.not <value>", `invoicing_entity_id__not`).option("--invoicing-entity-id.is-null <value>", `invoicing_entity_id__isNull`).option("--invoicing-entity-id.is-not-null <value>", `invoicing_entity_id__isNotNull`).option("--invoicing-entity-id.equals <value>", `invoicing_entity_id__equals`).option("--invoicing-entity-id.contains <value>", `invoicing_entity_id__contains`).option("--invoicing-entity-id.starts-with <value>", `invoicing_entity_id__startsWith`).option("--invoicing-entity-id.end-with <value>", `invoicing_entity_id__endWith`).option("--segment-id <value>", `segment_id`).option("--custom-properties <value>", `custom_properties`).option("--payment-method-type <value>", `payment_method_type`).option("--payment-method-type.in <value>", `payment_method_type__in`).option("--integration-entity-id <value>", `integration_entity_id`).option("--created-at <value>", `created_at`).option("--created-at.not <value>", `created_at__not`).option("--created-at.is-null <value>", `created_at__isNull`).option("--created-at.is-not-null <value>", `created_at__isNotNull`).option("--created-at.equals <value>", `created_at__equals`).option("--created-at.lt <value>", `created_at__lt`).option("--created-at.lte <value>", `created_at__lte`).option("--created-at.gt <value>", `created_at__gt`).option("--created-at.gte <value>", `created_at__gte`).option("--updated-at <value>", `updated_at`).option("--updated-at.not <value>", `updated_at__not`).option("--updated-at.is-null <value>", `updated_at__isNull`).option("--updated-at.is-not-null <value>", `updated_at__isNotNull`).option("--updated-at.equals <value>", `updated_at__equals`).option("--updated-at.lt <value>", `updated_at__lt`).option("--updated-at.lte <value>", `updated_at__lte`).option("--updated-at.gt <value>", `updated_at__gt`).option("--updated-at.gte <value>", `updated_at__gte`).addHelpText("after", `
38465
+ resource.command("list").description(`List customers with optional filters for name, type, status, currency, country, external_id, billing_email, search, tax_id, subscription_status, invoicing_entity_id, segment_id, custom_properties, payment_method_type, integration_entity_id, created_at, and updated_at. Sortable by created_at or updated_at. Paginated with limit/cursor.`).option("--limit <number>", `Maximum number of items to return (1-100).`).option("--cursor <value>", `Opaque cursor returned in the previous response's \`next_cursor\`. Omit to fetch the first page.`).option("--include-total <value>", `Set to \`true\` to include \`total\` in the response.`).option("--order <value>", `Sort direction.`).option("--sort <value>", `Field used to sort the results.`).option("--name <value>", `name`).option("--name.not <value>", `name__not`).option("--name.is-null <value>", `name__isNull`).option("--name.is-not-null <value>", `name__isNotNull`).option("--name.equals <value>", `name__equals`).option("--name.contains <value>", `name__contains`).option("--name.starts-with <value>", `name__startsWith`).option("--name.end-with <value>", `name__endWith`).option("--type <value>", `type`).option("--type.in <value>", `type__in`).option("--status <value>", `status`).option("--status.in <value>", `status__in`).option("--currency <value>", `currency`).option("--currency.not <value>", `currency__not`).option("--currency.is-null <value>", `currency__isNull`).option("--currency.is-not-null <value>", `currency__isNotNull`).option("--currency.equals <value>", `currency__equals`).option("--currency.contains <value>", `currency__contains`).option("--currency.starts-with <value>", `currency__startsWith`).option("--currency.end-with <value>", `currency__endWith`).option("--country <value>", `country`).option("--country.not <value>", `country__not`).option("--country.is-null <value>", `country__isNull`).option("--country.is-not-null <value>", `country__isNotNull`).option("--country.equals <value>", `country__equals`).option("--country.contains <value>", `country__contains`).option("--country.starts-with <value>", `country__startsWith`).option("--country.end-with <value>", `country__endWith`).option("--external-id <value>", `external_id`).option("--external-id.not <value>", `external_id__not`).option("--external-id.is-null <value>", `external_id__isNull`).option("--external-id.is-not-null <value>", `external_id__isNotNull`).option("--external-id.equals <value>", `external_id__equals`).option("--external-id.contains <value>", `external_id__contains`).option("--external-id.starts-with <value>", `external_id__startsWith`).option("--external-id.end-with <value>", `external_id__endWith`).option("--billing-email <value>", `billing_email`).option("--billing-email.not <value>", `billing_email__not`).option("--billing-email.is-null <value>", `billing_email__isNull`).option("--billing-email.is-not-null <value>", `billing_email__isNotNull`).option("--billing-email.equals <value>", `billing_email__equals`).option("--billing-email.contains <value>", `billing_email__contains`).option("--billing-email.starts-with <value>", `billing_email__startsWith`).option("--billing-email.end-with <value>", `billing_email__endWith`).option("--search <value>", `search`).option("--tax-id <value>", `tax_id`).option("--tax-id.not <value>", `tax_id__not`).option("--tax-id.is-null <value>", `tax_id__isNull`).option("--tax-id.is-not-null <value>", `tax_id__isNotNull`).option("--tax-id.equals <value>", `tax_id__equals`).option("--tax-id.contains <value>", `tax_id__contains`).option("--tax-id.starts-with <value>", `tax_id__startsWith`).option("--tax-id.end-with <value>", `tax_id__endWith`).option("--subscription-status <value>", `subscription_status`).option("--subscription-status.in <value>", `subscription_status__in`).option("--invoicing-entity-id <value>", `invoicing_entity_id`).option("--invoicing-entity-id.not <value>", `invoicing_entity_id__not`).option("--invoicing-entity-id.is-null <value>", `invoicing_entity_id__isNull`).option("--invoicing-entity-id.is-not-null <value>", `invoicing_entity_id__isNotNull`).option("--invoicing-entity-id.equals <value>", `invoicing_entity_id__equals`).option("--invoicing-entity-id.contains <value>", `invoicing_entity_id__contains`).option("--invoicing-entity-id.starts-with <value>", `invoicing_entity_id__startsWith`).option("--invoicing-entity-id.end-with <value>", `invoicing_entity_id__endWith`).option("--segment-id <value>", `segment_id`).option("--custom-properties <value>", `custom_properties`).option("--payment-method-type <value>", `payment_method_type`).option("--payment-method-type.in <value>", `payment_method_type__in`).option("--integration-entity-id <value>", `integration_entity_id`).option("--created-at <value>", `created_at`).option("--created-at.not <value>", `created_at__not`).option("--created-at.is-null <value>", `created_at__isNull`).option("--created-at.is-not-null <value>", `created_at__isNotNull`).option("--created-at.equals <value>", `created_at__equals`).option("--created-at.lt <value>", `created_at__lt`).option("--created-at.lte <value>", `created_at__lte`).option("--created-at.gt <value>", `created_at__gt`).option("--created-at.gte <value>", `created_at__gte`).option("--updated-at <value>", `updated_at`).option("--updated-at.not <value>", `updated_at__not`).option("--updated-at.is-null <value>", `updated_at__isNull`).option("--updated-at.is-not-null <value>", `updated_at__isNotNull`).option("--updated-at.equals <value>", `updated_at__equals`).option("--updated-at.lt <value>", `updated_at__lt`).option("--updated-at.lte <value>", `updated_at__lte`).option("--updated-at.gt <value>", `updated_at__gt`).option("--updated-at.gte <value>", `updated_at__gte`).addHelpText("after", `
38433
38466
  Examples:
38434
38467
  hyperline customers list
38435
- hyperline customers list --take <take> --name <name>`).action(async (opts) => {
38468
+ hyperline customers list --limit <limit> --cursor <cursor>`).action(async (opts) => {
38436
38469
  const ctx = resource.parent?.opts()._ctx;
38437
38470
  if (!ctx) {
38438
38471
  process.stderr.write("Error: Not authenticated\n");
38439
38472
  process.exit(1);
38440
38473
  }
38441
38474
  const args = {};
38475
+ if (opts.cursor !== void 0)
38476
+ args.cursor = opts.cursor;
38477
+ if (opts.includeTotal !== void 0)
38478
+ args.include_total = opts.includeTotal;
38479
+ if (opts.order !== void 0)
38480
+ args.order = opts.order;
38481
+ if (opts.sort !== void 0)
38482
+ args.sort = opts.sort;
38442
38483
  if (opts.name !== void 0)
38443
38484
  args.name = opts.name;
38444
38485
  if (opts["name.not"] !== void 0)
@@ -38611,17 +38652,18 @@ Examples:
38611
38652
  args.updated_at__gt = opts["updatedAt.gt"];
38612
38653
  if (opts["updatedAt.gte"] !== void 0)
38613
38654
  args.updated_at__gte = opts["updatedAt.gte"];
38614
- if (opts.take !== void 0)
38615
- args.take = Number(opts.take);
38616
- if (opts.skip !== void 0)
38617
- args.skip = Number(opts.skip);
38655
+ if (opts.limit !== void 0)
38656
+ args.limit = Number(opts.limit);
38618
38657
  await ctx.execute({
38619
38658
  method: "GET",
38620
- path: "/v1/customers",
38659
+ path: "/v2/customers",
38621
38660
  args,
38622
38661
  queryParamKeys: [
38623
- "take",
38624
- "skip",
38662
+ "limit",
38663
+ "cursor",
38664
+ "include_total",
38665
+ "order",
38666
+ "sort",
38625
38667
  "name",
38626
38668
  "name__not",
38627
38669
  "name__isNull",
@@ -38711,19 +38753,41 @@ Examples:
38711
38753
  ]
38712
38754
  });
38713
38755
  });
38756
+ resource.command("get").description(`Retrieve full details of a customer by ID including billing info, address, subscriptions, custom properties, integrations, payment method, and bank account.`).requiredOption("--id <value>", `id parameter`).addHelpText("after", `
38757
+ Examples:
38758
+ hyperline customers get --id <id>`).action(async (opts) => {
38759
+ const ctx = resource.parent?.opts()._ctx;
38760
+ if (!ctx) {
38761
+ process.stderr.write("Error: Not authenticated\n");
38762
+ process.exit(1);
38763
+ }
38764
+ const args = {};
38765
+ if (opts.id !== void 0)
38766
+ args.id = opts.id;
38767
+ await ctx.execute({
38768
+ method: "GET",
38769
+ path: "/v2/customers/{id}",
38770
+ args,
38771
+ queryParamKeys: []
38772
+ });
38773
+ });
38714
38774
  resource.command("create-customer").description(`Create a new customer with billing details, address, currency, and optional provider mappings. Returns the full customer object.`).option("--name <value>", `Customer name.`).option("--type <value>", `
38715
38775
  Customer type.
38716
38776
 
38717
38777
  - \`corporate\`: The customer is a business entity.
38718
38778
  - \`person\`: The customer is a natural person.
38719
38779
  - \`automatically_created\`: The customer was automatically imported (e.g. from a data loader). This value cannot be used when creating/editing.
38720
- `).option("--currency <value>", `Currency code. See [ISO 4217](https://en.wikipedia.org/wiki/ISO_4217#List_of_ISO_4217_currency_codes).`).option("--is-government-affiliated", `Indicates if the customer is affiliated with a government entity.`).option("--tax-ids <value>", `Customer tax IDs.`).option("--tax-rate-custom <number>", `Customer custom tax rate. If not defined, the rate will be automatically determined based on the customer's country, your country, and applicable legal requirements.`).option("--registration-number <value>", `Customer registration number.`).option("--external-id <value>", `ID of the customer in your system. This helps matching your customer with the one on Hyperline.`).option("--invoicing-entity-id <value>", `ID of the invoicing entity this customer will be attached to.`).option("--billing-address <value>", `Customer billing address.`).option("--shipping-address <value>", `Customer shipping address.`).option("--billing-email <value>", `Email to which all communications will be sent.`).option("--invoice-emails <value>", `Emails to which invoices will be sent (e.g. payer, finance team, accounting firm). If not defined, invoices will be sent to the \`billing_email\`; otherwise, they won't be sent to the \`billing_email\`.`).option("--language <value>", `Language used for invoices, emails, and hosted pages.`).option("--timezone <value>", `Customer timezone.`).option("--available-payment-methods <value>", `List of payment methods you allow your customer to pay with. You customer will be able to select one of them in their portal page and those will be the default options when creating a checkout session.`).option("--payment-method-type <value>", `Default payment method type used to pay subscriptions and one-off invoices.`).option("--bank-account <value>", `Custom bank account for the customer. If not defined and customer paying by bank transfer, the bank accounts configured in your account settings will be used.`).option("--custom-payment-delay <number>", `Custom payment delay. If not defined, the default one defined on the related invoicing entity will be used.`).option("--custom-payment-initiation-delay <number>", `Custom initiation delay for payment collection. If not defined, the default one defined on the related invoicing entity will be used.`).option("--organisation-id <value>", `Parent organization ID to which the client is attached.`).option("--organisation-invoicing <value>", `
38780
+ `).option("--currency <value>", `Currency code. See [ISO 4217](https://en.wikipedia.org/wiki/ISO_4217#List_of_ISO_4217_currency_codes).`).option("--is-government-affiliated", `Indicates if the customer is affiliated with a government entity.`).option("--tax-ids <value>", `Customer tax IDs.`).option("--tax-rate-custom <number>", `Customer custom tax rate. If not defined, the rate will be automatically determined based on the customer's country, your country, and applicable legal requirements.`).option("--taxability <value>", `Customer taxability.
38781
+
38782
+ - \`taxable\`: Taxes are automatically determined for the customer.
38783
+ - \`exempt\`: The customer is exempt from tax.
38784
+ `).option("--registration-number <value>", `Customer registration number.`).option("--external-id <value>", `ID of the customer in your system. This helps matching your customer with the one on Hyperline.`).option("--invoicing-entity-id <value>", `ID of the invoicing entity this customer will be attached to.`).option("--billing-address <value>", `Customer billing address.`).option("--shipping-address <value>", `Customer shipping address.`).option("--billing-email <value>", `Email to which all communications will be sent.`).option("--invoice-emails <value>", `Emails to which invoices will be sent (e.g. payer, finance team, accounting firm). If not defined, invoices will be sent to the \`billing_email\`; otherwise, they won't be sent to the \`billing_email\`.`).option("--language <value>", `Language used for invoices, emails, and hosted pages.`).option("--timezone <value>", `Customer timezone.`).option("--available-payment-methods <value>", `List of payment methods you allow your customer to pay with. You customer will be able to select one of them in their portal page and those will be the default options when creating a checkout session.`).option("--payment-method-type <value>", `Default payment method type used to pay subscriptions and one-off invoices.`).option("--bank-account <value>", `Custom bank account for the customer. If not defined and customer paying by bank transfer, the bank accounts configured in your account settings will be used.`).option("--custom-payment-delay <number>", `Custom payment terms in days. If not defined, the default one defined on the related invoicing entity will be used.`).option("--custom-payment-initiation-delay <number>", `Custom initiation delay in days before triggering payment. If not defined, the default one defined on the related invoicing entity will be used.`).option("--organisation-id <value>", `Parent organization ID to which the client is attached.`).option("--organisation-invoicing <value>", `
38721
38785
  How customer invoices are issued from the parent organisation.
38722
38786
 
38723
38787
  - \`none\`: Invoices will keep being issued from this customer.
38724
38788
  - \`every_invoice\`: Customer invoices will be issued from the organisation individually.
38725
38789
  - \`concat\`: Customer invoices will be grouped into a global parent invoice at a regular schedule (configured on the organisation).
38726
- `).option("--properties <value>", `Key/value pairs to store any metadata useful in your context.`).option("--custom-properties <value>", `A list of key value with the slug of the custom property as the key and the custom property value as value.`).option("--invoice-reminders-enabled <value>", `Indicates if invoice reminders are enabled for the customer.`).option("--price-book-id <value>", `Default price book ID assigned to the customer.`).addHelpText("after", `
38790
+ `).option("--properties <value>", `Key/value pairs to store any metadata useful in your context.`).option("--custom-properties <value>", `A list of key value with the slug of the custom property as the key and the custom property value as value.`).option("--invoice-reminders-enabled <value>", `Indicates if invoice reminders are enabled for the customer.`).option("--price-book-id <value>", `Default price book ID assigned to the customer.`).option("--owner-id <value>", `ID of the Hyperline user responsible for this customer and targeted by customer agent notifications.`).option("--follower-ids <value>", `IDs of Hyperline users following this customer.`).addHelpText("after", `
38727
38791
  Examples:
38728
38792
  hyperline customers create-customer
38729
38793
  hyperline customers create-customer --name <name> --type <type>
@@ -38742,6 +38806,8 @@ Examples:
38742
38806
  args.currency = opts.currency;
38743
38807
  if (opts.taxIds !== void 0)
38744
38808
  args.tax_ids = opts.taxIds;
38809
+ if (opts.taxability !== void 0)
38810
+ args.taxability = opts.taxability;
38745
38811
  if (opts.registrationNumber !== void 0)
38746
38812
  args.registration_number = opts.registrationNumber;
38747
38813
  if (opts.externalId !== void 0)
@@ -38778,6 +38844,10 @@ Examples:
38778
38844
  args.invoice_reminders_enabled = opts.invoiceRemindersEnabled;
38779
38845
  if (opts.priceBookId !== void 0)
38780
38846
  args.price_book_id = opts.priceBookId;
38847
+ if (opts.ownerId !== void 0)
38848
+ args.owner_id = opts.ownerId;
38849
+ if (opts.followerIds !== void 0)
38850
+ args.follower_ids = opts.followerIds;
38781
38851
  if (opts.taxRateCustom !== void 0)
38782
38852
  args.tax_rate_custom = Number(opts.taxRateCustom);
38783
38853
  if (opts.customPaymentDelay !== void 0)
@@ -38812,24 +38882,6 @@ Examples:
38812
38882
  queryParamKeys: []
38813
38883
  });
38814
38884
  });
38815
- resource.command("get").description(`Retrieve full details of a customer by ID including billing info, address, subscriptions, custom properties, and provider mappings.`).requiredOption("--id <value>", `id parameter`).addHelpText("after", `
38816
- Examples:
38817
- hyperline customers get --id <id>`).action(async (opts) => {
38818
- const ctx = resource.parent?.opts()._ctx;
38819
- if (!ctx) {
38820
- process.stderr.write("Error: Not authenticated\n");
38821
- process.exit(1);
38822
- }
38823
- const args = {};
38824
- if (opts.id !== void 0)
38825
- args.id = opts.id;
38826
- await ctx.execute({
38827
- method: "GET",
38828
- path: "/v1/customers/{id}",
38829
- args,
38830
- queryParamKeys: []
38831
- });
38832
- });
38833
38885
  resource.command("get-customer-portal-url").description(`Get a portal URL for a customer. The portal allows the customer to view invoices, update payment methods, and manage their account.`).requiredOption("--id <value>", `id parameter`).addHelpText("after", `
38834
38886
  Examples:
38835
38887
  hyperline customers get-customer-portal-url --id <id>`).action(async (opts) => {
@@ -38854,13 +38906,17 @@ Customer type.
38854
38906
  - \`corporate\`: The customer is a business entity.
38855
38907
  - \`person\`: The customer is a natural person.
38856
38908
  - \`automatically_created\`: The customer was automatically imported (e.g. from a data loader). This value cannot be used when creating/editing.
38857
- `).option("--currency <value>", `Customer currency. Can only be changed if the customer doesn't have existing invoices, a wallet or a payment method saved.`).option("--tax-ids <value>", `Customer tax IDs.`).option("--tax-rate-custom <number>", `Customer custom tax rate. If not defined, the rate will be automatically determined based on the customer's country, your country, and applicable legal requirements.`).option("--registration-number <value>", `Customer registration number.`).option("--is-government-affiliated", `Indicates if the customer is affiliated with a government entity.`).option("--external-id <value>", `ID of the customer in your system. This helps matching your customer with the one on Hyperline.`).option("--invoicing-entity-id <value>", `ID of the invoicing entity this customer will be attached to.`).option("--billing-address <value>", `Customer billing address.`).option("--shipping-address <value>", `Customer shipping address.`).option("--billing-email <value>", `Email to which all communications will be sent.`).option("--invoice-emails <value>", `Emails to which invoices will be sent (e.g. payer, finance team, accounting firm). If not defined, invoices will be sent to the \`billing_email\`; otherwise, they won't be sent to the \`billing_email\`.`).option("--language <value>", `Language used for invoices, emails, and hosted pages.`).option("--timezone <value>", `Customer timezone.`).option("--available-payment-methods <value>", `List of payment methods you allow your customer to pay with. You customer will be able to select one of them in their portal page and those will be the default options when creating a checkout session.`).option("--payment-method-type <value>", `Default payment method type used to pay subscriptions and one-off invoices.`).option("--payment-method-id <value>", `ID of the default payment method of the customer. Only applies to card and direct debit.`).option("--bank-account <value>", `Custom bank account for the customer. If not defined and customer paying by bank transfer, the bank accounts configured in your account settings will be used.`).option("--custom-payment-delay <number>", `Custom payment delay. If not defined, the default one defined on the related invoicing entity will be used.`).option("--custom-payment-initiation-delay <number>", `Custom initiation delay for payment collection. If not defined, the default one defined on the related invoicing entity will be used.`).option("--organisation-id <value>", `Parent organization ID to which the client is attached.`).option("--organisation-invoicing <value>", `
38909
+ `).option("--currency <value>", `Customer currency. Can only be changed if the customer doesn't have existing invoices, a wallet or a payment method saved.`).option("--tax-ids <value>", `Customer tax IDs.`).option("--tax-rate-custom <number>", `Customer custom tax rate. If not defined, the rate will be automatically determined based on the customer's country, your country, and applicable legal requirements.`).option("--taxability <value>", `Customer taxability.
38910
+
38911
+ - \`taxable\`: Taxes are automatically determined for the customer.
38912
+ - \`exempt\`: The customer is exempt from tax.
38913
+ `).option("--registration-number <value>", `Customer registration number.`).option("--is-government-affiliated", `Indicates if the customer is affiliated with a government entity.`).option("--external-id <value>", `ID of the customer in your system. This helps matching your customer with the one on Hyperline.`).option("--invoicing-entity-id <value>", `ID of the invoicing entity this customer will be attached to.`).option("--billing-address <value>", `Customer billing address.`).option("--shipping-address <value>", `Customer shipping address.`).option("--billing-email <value>", `Email to which all communications will be sent.`).option("--invoice-emails <value>", `Emails to which invoices will be sent (e.g. payer, finance team, accounting firm). If not defined, invoices will be sent to the \`billing_email\`; otherwise, they won't be sent to the \`billing_email\`.`).option("--language <value>", `Language used for invoices, emails, and hosted pages.`).option("--timezone <value>", `Customer timezone.`).option("--available-payment-methods <value>", `List of payment methods you allow your customer to pay with. You customer will be able to select one of them in their portal page and those will be the default options when creating a checkout session.`).option("--payment-method-type <value>", `Default payment method type used to pay subscriptions and one-off invoices.`).option("--payment-method-id <value>", `ID of the default payment method of the customer. Only applies to card and direct debit.`).option("--bank-account <value>", `Custom bank account for the customer. If not defined and customer paying by bank transfer, the bank accounts configured in your account settings will be used.`).option("--custom-payment-delay <number>", `Custom payment terms in days. If not defined, the default one defined on the related invoicing entity will be used.`).option("--custom-payment-initiation-delay <number>", `Custom initiation delay in days before triggering payment. If not defined, the default one defined on the related invoicing entity will be used.`).option("--organisation-id <value>", `Parent organization ID to which the client is attached.`).option("--organisation-invoicing <value>", `
38858
38914
  How customer invoices are issued from the parent organisation.
38859
38915
 
38860
38916
  - \`none\`: Invoices will keep being issued from this customer.
38861
38917
  - \`every_invoice\`: Customer invoices will be issued from the organisation individually.
38862
38918
  - \`concat\`: Customer invoices will be grouped into a global parent invoice at a regular schedule (configured on the organisation).
38863
- `).option("--properties <value>", `Key/value pairs to store any metadata useful in your context.`).option("--custom-properties <value>", `A list of key value with the slug of the custom property as the key and the custom property value as value.`).option("--invoice-reminders-enabled <value>", `Indicates if invoice reminders are enabled for the customer.`).option("--price-book-id <value>", `Default price book ID assigned to the customer.`).addHelpText("after", `
38919
+ `).option("--properties <value>", `Key/value pairs to store any metadata useful in your context.`).option("--custom-properties <value>", `A list of key value with the slug of the custom property as the key and the custom property value as value.`).option("--invoice-reminders-enabled <value>", `Indicates if invoice reminders are enabled for the customer.`).option("--price-book-id <value>", `Default price book ID assigned to the customer.`).option("--owner-id <value>", `ID of the Hyperline user responsible for this customer and targeted by customer agent notifications.`).option("--follower-ids <value>", `IDs of Hyperline users following this customer.`).addHelpText("after", `
38864
38920
  Examples:
38865
38921
  hyperline customers update --id <id>
38866
38922
  hyperline customers update --id <id> --name <name> --type <type>
@@ -38881,6 +38937,8 @@ Examples:
38881
38937
  args.currency = opts.currency;
38882
38938
  if (opts.taxIds !== void 0)
38883
38939
  args.tax_ids = opts.taxIds;
38940
+ if (opts.taxability !== void 0)
38941
+ args.taxability = opts.taxability;
38884
38942
  if (opts.registrationNumber !== void 0)
38885
38943
  args.registration_number = opts.registrationNumber;
38886
38944
  if (opts.externalId !== void 0)
@@ -38919,6 +38977,10 @@ Examples:
38919
38977
  args.invoice_reminders_enabled = opts.invoiceRemindersEnabled;
38920
38978
  if (opts.priceBookId !== void 0)
38921
38979
  args.price_book_id = opts.priceBookId;
38980
+ if (opts.ownerId !== void 0)
38981
+ args.owner_id = opts.ownerId;
38982
+ if (opts.followerIds !== void 0)
38983
+ args.follower_ids = opts.followerIds;
38922
38984
  if (opts.taxRateCustom !== void 0)
38923
38985
  args.tax_rate_custom = Number(opts.taxRateCustom);
38924
38986
  if (opts.customPaymentDelay !== void 0)
@@ -39583,6 +39645,7 @@ Export name.
39583
39645
  - \`draft_invoices\`: Export all draft invoices, with customer and product information.
39584
39646
  - \`open_invoices\`: Export all open invoices, with customer and product information.
39585
39647
  - \`live_subscriptions\`: List of all active subscriptions line by line.
39648
+ - \`credit_balances\`: Monthly credit balance roll-forward per customer and credit type (opening, top-ups, consumption, expiry, closing).
39586
39649
  `).requiredOption("--file-type <value>", `
39587
39650
  Export file type.
39588
39651
 
@@ -39816,16 +39879,20 @@ Examples:
39816
39879
  // build/commands/generated/invoices.js
39817
39880
  function registerInvoicesCommands(parent) {
39818
39881
  const resource = parent.command("invoices").description("Manage invoices");
39819
- resource.command("list").description(`List invoices with filters for type, status, customer_id, customer_external_id, subscription_id, invoicing_entity_id, invoice_number, period dates, emission_date, due_date, and updated_at. Sortable by created_at or emitted_at. By default, open invoices are excluded. Paginated with take/skip.`).option("--take <number>", `take`).option("--skip <number>", `skip`).option("--order <value>", `Sort direction.`).option("--sort <value>", `Field used to sort the results.`).option("--type <value>", `type`).option("--type.in <value>", `type__in`).option("--status <value>", `status`).option("--status.in <value>", `status__in`).option("--customer-id <value>", `customer_id`).option("--customer-id.not <value>", `customer_id__not`).option("--customer-id.is-null <value>", `customer_id__isNull`).option("--customer-id.is-not-null <value>", `customer_id__isNotNull`).option("--customer-id.equals <value>", `customer_id__equals`).option("--customer-id.contains <value>", `customer_id__contains`).option("--customer-id.starts-with <value>", `customer_id__startsWith`).option("--customer-id.end-with <value>", `customer_id__endWith`).option("--customer-external-id <value>", `customer_external_id`).option("--subscription-id <value>", `subscription_id`).option("--subscription-id.not <value>", `subscription_id__not`).option("--subscription-id.is-null <value>", `subscription_id__isNull`).option("--subscription-id.is-not-null <value>", `subscription_id__isNotNull`).option("--subscription-id.equals <value>", `subscription_id__equals`).option("--subscription-id.contains <value>", `subscription_id__contains`).option("--subscription-id.starts-with <value>", `subscription_id__startsWith`).option("--subscription-id.end-with <value>", `subscription_id__endWith`).option("--invoicing-entity-id <value>", `invoicing_entity_id`).option("--invoicing-entity-id.not <value>", `invoicing_entity_id__not`).option("--invoicing-entity-id.is-null <value>", `invoicing_entity_id__isNull`).option("--invoicing-entity-id.is-not-null <value>", `invoicing_entity_id__isNotNull`).option("--invoicing-entity-id.equals <value>", `invoicing_entity_id__equals`).option("--invoicing-entity-id.contains <value>", `invoicing_entity_id__contains`).option("--invoicing-entity-id.starts-with <value>", `invoicing_entity_id__startsWith`).option("--invoicing-entity-id.end-with <value>", `invoicing_entity_id__endWith`).option("--invoice-number <value>", `invoice_number`).option("--invoice-number.not <value>", `invoice_number__not`).option("--invoice-number.is-null <value>", `invoice_number__isNull`).option("--invoice-number.is-not-null <value>", `invoice_number__isNotNull`).option("--invoice-number.equals <value>", `invoice_number__equals`).option("--invoice-number.contains <value>", `invoice_number__contains`).option("--invoice-number.starts-with <value>", `invoice_number__startsWith`).option("--invoice-number.end-with <value>", `invoice_number__endWith`).option("--original-invoice-id <value>", `original_invoice_id`).option("--original-invoice-id.not <value>", `original_invoice_id__not`).option("--original-invoice-id.is-null <value>", `original_invoice_id__isNull`).option("--original-invoice-id.is-not-null <value>", `original_invoice_id__isNotNull`).option("--original-invoice-id.equals <value>", `original_invoice_id__equals`).option("--original-invoice-id.contains <value>", `original_invoice_id__contains`).option("--original-invoice-id.starts-with <value>", `original_invoice_id__startsWith`).option("--original-invoice-id.end-with <value>", `original_invoice_id__endWith`).option("--original-invoice-number <value>", `original_invoice_number`).option("--original-invoice-number.not <value>", `original_invoice_number__not`).option("--original-invoice-number.is-null <value>", `original_invoice_number__isNull`).option("--original-invoice-number.is-not-null <value>", `original_invoice_number__isNotNull`).option("--original-invoice-number.equals <value>", `original_invoice_number__equals`).option("--original-invoice-number.contains <value>", `original_invoice_number__contains`).option("--original-invoice-number.starts-with <value>", `original_invoice_number__startsWith`).option("--original-invoice-number.end-with <value>", `original_invoice_number__endWith`).option("--line-item-id <value>", `line_item_id`).option("--period-start <value>", `period_start`).option("--period-start.not <value>", `period_start__not`).option("--period-start.is-null <value>", `period_start__isNull`).option("--period-start.is-not-null <value>", `period_start__isNotNull`).option("--period-start.equals <value>", `period_start__equals`).option("--period-start.lt <value>", `period_start__lt`).option("--period-start.lte <value>", `period_start__lte`).option("--period-start.gt <value>", `period_start__gt`).option("--period-start.gte <value>", `period_start__gte`).option("--period-end <value>", `period_end`).option("--period-end.not <value>", `period_end__not`).option("--period-end.is-null <value>", `period_end__isNull`).option("--period-end.is-not-null <value>", `period_end__isNotNull`).option("--period-end.equals <value>", `period_end__equals`).option("--period-end.lt <value>", `period_end__lt`).option("--period-end.lte <value>", `period_end__lte`).option("--period-end.gt <value>", `period_end__gt`).option("--period-end.gte <value>", `period_end__gte`).option("--emission-date <value>", `emission_date`).option("--emission-date.not <value>", `emission_date__not`).option("--emission-date.is-null <value>", `emission_date__isNull`).option("--emission-date.is-not-null <value>", `emission_date__isNotNull`).option("--emission-date.equals <value>", `emission_date__equals`).option("--emission-date.lt <value>", `emission_date__lt`).option("--emission-date.lte <value>", `emission_date__lte`).option("--emission-date.gt <value>", `emission_date__gt`).option("--emission-date.gte <value>", `emission_date__gte`).option("--due-date <value>", `due_date`).option("--due-date.not <value>", `due_date__not`).option("--due-date.is-null <value>", `due_date__isNull`).option("--due-date.is-not-null <value>", `due_date__isNotNull`).option("--due-date.equals <value>", `due_date__equals`).option("--due-date.lt <value>", `due_date__lt`).option("--due-date.lte <value>", `due_date__lte`).option("--due-date.gt <value>", `due_date__gt`).option("--due-date.gte <value>", `due_date__gte`).option("--updated-at <value>", `updated_at`).option("--updated-at.not <value>", `updated_at__not`).option("--updated-at.is-null <value>", `updated_at__isNull`).option("--updated-at.is-not-null <value>", `updated_at__isNotNull`).option("--updated-at.equals <value>", `updated_at__equals`).option("--updated-at.lt <value>", `updated_at__lt`).option("--updated-at.lte <value>", `updated_at__lte`).option("--updated-at.gt <value>", `updated_at__gt`).option("--updated-at.gte <value>", `updated_at__gte`).addHelpText("after", `
39882
+ resource.command("list").description(`List invoices with filters for type, status, customer_id, customer_external_id, subscription_id, invoicing_entity_id, invoice_number, period dates, emission_date, due_date, and updated_at. Sortable by created_at or emitted_at. By default, open invoices are excluded. Paginated with limit/cursor.`).option("--limit <number>", `Maximum number of items to return (1-100).`).option("--cursor <value>", `Opaque cursor returned in the previous response's \`next_cursor\`. Omit to fetch the first page.`).option("--include-total <value>", `Set to \`true\` to include \`total\` in the response.`).option("--order <value>", `Sort direction.`).option("--sort <value>", `Field used to sort the results.`).option("--type <value>", `type`).option("--type.in <value>", `type__in`).option("--status <value>", `status`).option("--status.in <value>", `status__in`).option("--customer-id <value>", `customer_id`).option("--customer-id.not <value>", `customer_id__not`).option("--customer-id.is-null <value>", `customer_id__isNull`).option("--customer-id.is-not-null <value>", `customer_id__isNotNull`).option("--customer-id.equals <value>", `customer_id__equals`).option("--customer-id.contains <value>", `customer_id__contains`).option("--customer-id.starts-with <value>", `customer_id__startsWith`).option("--customer-id.end-with <value>", `customer_id__endWith`).option("--customer-external-id <value>", `customer_external_id`).option("--subscription-id <value>", `subscription_id`).option("--subscription-id.not <value>", `subscription_id__not`).option("--subscription-id.is-null <value>", `subscription_id__isNull`).option("--subscription-id.is-not-null <value>", `subscription_id__isNotNull`).option("--subscription-id.equals <value>", `subscription_id__equals`).option("--subscription-id.contains <value>", `subscription_id__contains`).option("--subscription-id.starts-with <value>", `subscription_id__startsWith`).option("--subscription-id.end-with <value>", `subscription_id__endWith`).option("--invoicing-entity-id <value>", `invoicing_entity_id`).option("--invoicing-entity-id.not <value>", `invoicing_entity_id__not`).option("--invoicing-entity-id.is-null <value>", `invoicing_entity_id__isNull`).option("--invoicing-entity-id.is-not-null <value>", `invoicing_entity_id__isNotNull`).option("--invoicing-entity-id.equals <value>", `invoicing_entity_id__equals`).option("--invoicing-entity-id.contains <value>", `invoicing_entity_id__contains`).option("--invoicing-entity-id.starts-with <value>", `invoicing_entity_id__startsWith`).option("--invoicing-entity-id.end-with <value>", `invoicing_entity_id__endWith`).option("--invoice-number <value>", `invoice_number`).option("--invoice-number.not <value>", `invoice_number__not`).option("--invoice-number.is-null <value>", `invoice_number__isNull`).option("--invoice-number.is-not-null <value>", `invoice_number__isNotNull`).option("--invoice-number.equals <value>", `invoice_number__equals`).option("--invoice-number.contains <value>", `invoice_number__contains`).option("--invoice-number.starts-with <value>", `invoice_number__startsWith`).option("--invoice-number.end-with <value>", `invoice_number__endWith`).option("--original-invoice-id <value>", `original_invoice_id`).option("--original-invoice-id.not <value>", `original_invoice_id__not`).option("--original-invoice-id.is-null <value>", `original_invoice_id__isNull`).option("--original-invoice-id.is-not-null <value>", `original_invoice_id__isNotNull`).option("--original-invoice-id.equals <value>", `original_invoice_id__equals`).option("--original-invoice-id.contains <value>", `original_invoice_id__contains`).option("--original-invoice-id.starts-with <value>", `original_invoice_id__startsWith`).option("--original-invoice-id.end-with <value>", `original_invoice_id__endWith`).option("--original-invoice-number <value>", `original_invoice_number`).option("--original-invoice-number.not <value>", `original_invoice_number__not`).option("--original-invoice-number.is-null <value>", `original_invoice_number__isNull`).option("--original-invoice-number.is-not-null <value>", `original_invoice_number__isNotNull`).option("--original-invoice-number.equals <value>", `original_invoice_number__equals`).option("--original-invoice-number.contains <value>", `original_invoice_number__contains`).option("--original-invoice-number.starts-with <value>", `original_invoice_number__startsWith`).option("--original-invoice-number.end-with <value>", `original_invoice_number__endWith`).option("--line-item-id <value>", `line_item_id`).option("--period-start <value>", `period_start`).option("--period-start.not <value>", `period_start__not`).option("--period-start.is-null <value>", `period_start__isNull`).option("--period-start.is-not-null <value>", `period_start__isNotNull`).option("--period-start.equals <value>", `period_start__equals`).option("--period-start.lt <value>", `period_start__lt`).option("--period-start.lte <value>", `period_start__lte`).option("--period-start.gt <value>", `period_start__gt`).option("--period-start.gte <value>", `period_start__gte`).option("--period-end <value>", `period_end`).option("--period-end.not <value>", `period_end__not`).option("--period-end.is-null <value>", `period_end__isNull`).option("--period-end.is-not-null <value>", `period_end__isNotNull`).option("--period-end.equals <value>", `period_end__equals`).option("--period-end.lt <value>", `period_end__lt`).option("--period-end.lte <value>", `period_end__lte`).option("--period-end.gt <value>", `period_end__gt`).option("--period-end.gte <value>", `period_end__gte`).option("--issued-at <value>", `issued_at`).option("--issued-at.not <value>", `issued_at__not`).option("--issued-at.is-null <value>", `issued_at__isNull`).option("--issued-at.is-not-null <value>", `issued_at__isNotNull`).option("--issued-at.equals <value>", `issued_at__equals`).option("--issued-at.lt <value>", `issued_at__lt`).option("--issued-at.lte <value>", `issued_at__lte`).option("--issued-at.gt <value>", `issued_at__gt`).option("--issued-at.gte <value>", `issued_at__gte`).option("--due-at <value>", `due_at`).option("--due-at.not <value>", `due_at__not`).option("--due-at.is-null <value>", `due_at__isNull`).option("--due-at.is-not-null <value>", `due_at__isNotNull`).option("--due-at.equals <value>", `due_at__equals`).option("--due-at.lt <value>", `due_at__lt`).option("--due-at.lte <value>", `due_at__lte`).option("--due-at.gt <value>", `due_at__gt`).option("--due-at.gte <value>", `due_at__gte`).option("--updated-at <value>", `updated_at`).option("--updated-at.not <value>", `updated_at__not`).option("--updated-at.is-null <value>", `updated_at__isNull`).option("--updated-at.is-not-null <value>", `updated_at__isNotNull`).option("--updated-at.equals <value>", `updated_at__equals`).option("--updated-at.lt <value>", `updated_at__lt`).option("--updated-at.lte <value>", `updated_at__lte`).option("--updated-at.gt <value>", `updated_at__gt`).option("--updated-at.gte <value>", `updated_at__gte`).addHelpText("after", `
39820
39883
  Examples:
39821
39884
  hyperline invoices list
39822
- hyperline invoices list --take <take> --order <order>`).action(async (opts) => {
39885
+ hyperline invoices list --limit <limit> --cursor <cursor>`).action(async (opts) => {
39823
39886
  const ctx = resource.parent?.opts()._ctx;
39824
39887
  if (!ctx) {
39825
39888
  process.stderr.write("Error: Not authenticated\n");
39826
39889
  process.exit(1);
39827
39890
  }
39828
39891
  const args = {};
39892
+ if (opts.cursor !== void 0)
39893
+ args.cursor = opts.cursor;
39894
+ if (opts.includeTotal !== void 0)
39895
+ args.include_total = opts.includeTotal;
39829
39896
  if (opts.order !== void 0)
39830
39897
  args.order = opts.order;
39831
39898
  if (opts.sort !== void 0)
@@ -39974,42 +40041,42 @@ Examples:
39974
40041
  args.period_end__gt = opts["periodEnd.gt"];
39975
40042
  if (opts["periodEnd.gte"] !== void 0)
39976
40043
  args.period_end__gte = opts["periodEnd.gte"];
39977
- if (opts.emissionDate !== void 0)
39978
- args.emission_date = opts.emissionDate;
39979
- if (opts["emissionDate.not"] !== void 0)
39980
- args.emission_date__not = opts["emissionDate.not"];
39981
- if (opts["emissionDate.isNull"] !== void 0)
39982
- args.emission_date__isNull = opts["emissionDate.isNull"];
39983
- if (opts["emissionDate.isNotNull"] !== void 0)
39984
- args.emission_date__isNotNull = opts["emissionDate.isNotNull"];
39985
- if (opts["emissionDate.equals"] !== void 0)
39986
- args.emission_date__equals = opts["emissionDate.equals"];
39987
- if (opts["emissionDate.lt"] !== void 0)
39988
- args.emission_date__lt = opts["emissionDate.lt"];
39989
- if (opts["emissionDate.lte"] !== void 0)
39990
- args.emission_date__lte = opts["emissionDate.lte"];
39991
- if (opts["emissionDate.gt"] !== void 0)
39992
- args.emission_date__gt = opts["emissionDate.gt"];
39993
- if (opts["emissionDate.gte"] !== void 0)
39994
- args.emission_date__gte = opts["emissionDate.gte"];
39995
- if (opts.dueDate !== void 0)
39996
- args.due_date = opts.dueDate;
39997
- if (opts["dueDate.not"] !== void 0)
39998
- args.due_date__not = opts["dueDate.not"];
39999
- if (opts["dueDate.isNull"] !== void 0)
40000
- args.due_date__isNull = opts["dueDate.isNull"];
40001
- if (opts["dueDate.isNotNull"] !== void 0)
40002
- args.due_date__isNotNull = opts["dueDate.isNotNull"];
40003
- if (opts["dueDate.equals"] !== void 0)
40004
- args.due_date__equals = opts["dueDate.equals"];
40005
- if (opts["dueDate.lt"] !== void 0)
40006
- args.due_date__lt = opts["dueDate.lt"];
40007
- if (opts["dueDate.lte"] !== void 0)
40008
- args.due_date__lte = opts["dueDate.lte"];
40009
- if (opts["dueDate.gt"] !== void 0)
40010
- args.due_date__gt = opts["dueDate.gt"];
40011
- if (opts["dueDate.gte"] !== void 0)
40012
- args.due_date__gte = opts["dueDate.gte"];
40044
+ if (opts.issuedAt !== void 0)
40045
+ args.issued_at = opts.issuedAt;
40046
+ if (opts["issuedAt.not"] !== void 0)
40047
+ args.issued_at__not = opts["issuedAt.not"];
40048
+ if (opts["issuedAt.isNull"] !== void 0)
40049
+ args.issued_at__isNull = opts["issuedAt.isNull"];
40050
+ if (opts["issuedAt.isNotNull"] !== void 0)
40051
+ args.issued_at__isNotNull = opts["issuedAt.isNotNull"];
40052
+ if (opts["issuedAt.equals"] !== void 0)
40053
+ args.issued_at__equals = opts["issuedAt.equals"];
40054
+ if (opts["issuedAt.lt"] !== void 0)
40055
+ args.issued_at__lt = opts["issuedAt.lt"];
40056
+ if (opts["issuedAt.lte"] !== void 0)
40057
+ args.issued_at__lte = opts["issuedAt.lte"];
40058
+ if (opts["issuedAt.gt"] !== void 0)
40059
+ args.issued_at__gt = opts["issuedAt.gt"];
40060
+ if (opts["issuedAt.gte"] !== void 0)
40061
+ args.issued_at__gte = opts["issuedAt.gte"];
40062
+ if (opts.dueAt !== void 0)
40063
+ args.due_at = opts.dueAt;
40064
+ if (opts["dueAt.not"] !== void 0)
40065
+ args.due_at__not = opts["dueAt.not"];
40066
+ if (opts["dueAt.isNull"] !== void 0)
40067
+ args.due_at__isNull = opts["dueAt.isNull"];
40068
+ if (opts["dueAt.isNotNull"] !== void 0)
40069
+ args.due_at__isNotNull = opts["dueAt.isNotNull"];
40070
+ if (opts["dueAt.equals"] !== void 0)
40071
+ args.due_at__equals = opts["dueAt.equals"];
40072
+ if (opts["dueAt.lt"] !== void 0)
40073
+ args.due_at__lt = opts["dueAt.lt"];
40074
+ if (opts["dueAt.lte"] !== void 0)
40075
+ args.due_at__lte = opts["dueAt.lte"];
40076
+ if (opts["dueAt.gt"] !== void 0)
40077
+ args.due_at__gt = opts["dueAt.gt"];
40078
+ if (opts["dueAt.gte"] !== void 0)
40079
+ args.due_at__gte = opts["dueAt.gte"];
40013
40080
  if (opts.updatedAt !== void 0)
40014
40081
  args.updated_at = opts.updatedAt;
40015
40082
  if (opts["updatedAt.not"] !== void 0)
@@ -40028,17 +40095,16 @@ Examples:
40028
40095
  args.updated_at__gt = opts["updatedAt.gt"];
40029
40096
  if (opts["updatedAt.gte"] !== void 0)
40030
40097
  args.updated_at__gte = opts["updatedAt.gte"];
40031
- if (opts.take !== void 0)
40032
- args.take = Number(opts.take);
40033
- if (opts.skip !== void 0)
40034
- args.skip = Number(opts.skip);
40098
+ if (opts.limit !== void 0)
40099
+ args.limit = Number(opts.limit);
40035
40100
  await ctx.execute({
40036
40101
  method: "GET",
40037
- path: "/v1/invoices",
40102
+ path: "/v2/invoices",
40038
40103
  args,
40039
40104
  queryParamKeys: [
40040
- "take",
40041
- "skip",
40105
+ "limit",
40106
+ "cursor",
40107
+ "include_total",
40042
40108
  "order",
40043
40109
  "sort",
40044
40110
  "type",
@@ -40113,24 +40179,24 @@ Examples:
40113
40179
  "period_end__lte",
40114
40180
  "period_end__gt",
40115
40181
  "period_end__gte",
40116
- "emission_date",
40117
- "emission_date__not",
40118
- "emission_date__isNull",
40119
- "emission_date__isNotNull",
40120
- "emission_date__equals",
40121
- "emission_date__lt",
40122
- "emission_date__lte",
40123
- "emission_date__gt",
40124
- "emission_date__gte",
40125
- "due_date",
40126
- "due_date__not",
40127
- "due_date__isNull",
40128
- "due_date__isNotNull",
40129
- "due_date__equals",
40130
- "due_date__lt",
40131
- "due_date__lte",
40132
- "due_date__gt",
40133
- "due_date__gte",
40182
+ "issued_at",
40183
+ "issued_at__not",
40184
+ "issued_at__isNull",
40185
+ "issued_at__isNotNull",
40186
+ "issued_at__equals",
40187
+ "issued_at__lt",
40188
+ "issued_at__lte",
40189
+ "issued_at__gt",
40190
+ "issued_at__gte",
40191
+ "due_at",
40192
+ "due_at__not",
40193
+ "due_at__isNull",
40194
+ "due_at__isNotNull",
40195
+ "due_at__equals",
40196
+ "due_at__lt",
40197
+ "due_at__lte",
40198
+ "due_at__gt",
40199
+ "due_at__gte",
40134
40200
  "updated_at",
40135
40201
  "updated_at__not",
40136
40202
  "updated_at__isNull",
@@ -40157,7 +40223,7 @@ Examples:
40157
40223
  - \`archived\`: A previous version of an invoice.
40158
40224
  - \`charged_on_parent\`: Invoice is charged on the parent customer.
40159
40225
  - \`pending_parent_concat\`: Invoice is pending invoices concatenation on the parent customer to be grouped.
40160
- - \`uncollectible\`: Invoice is uncollectible (bad debt).
40226
+ - \`uncollectible\`: Invoice is uncollectible (bad debt). Only metadata (properties, custom_note, custom_properties) can be updated in this status.
40161
40227
  `).option("--invoicing-entity-id <value>", `ID of the invoicing entity attached to the invoice.`).option("--number <value>", `Invoice number. If specified, the invoice will be considered as imported from an external source and the number will not be generated by Hyperline. You are responsible for avoiding duplicates and ensuring it does not impact the numbering sequence in Hyperline.`).option("--type <value>", `Type of the invoice.
40162
40228
 
40163
40229
  - \`invoice\`: Legal invoice to be paid by your customer.
@@ -40172,7 +40238,7 @@ Payment method strategy used to charge the invoice. Only applies to \`to_pay\` s
40172
40238
 
40173
40239
  - \`current\`: Use the current default payment method of the customer.
40174
40240
  - \`external\`: Manage the payment of the invoice outside of Hyperline.
40175
- `).option("--payment-method-id <value>", `ID of the default payment method used to pay the invoice. Transactions related to the invoice may use different payment methods.`).option("--bank-account-id <value>", `ID of the bank account displayed on the invoice. Transactions related to the invoice may use different bank accounts.`).option("--subscription-id <value>", `ID of the subscription related to the invoice.`).option("--emitted-at <value>", `Issue date of the invoice.`).option("--due-at <value>", `Due date of the invoice. Computed from the issue date and the payment delay configured in your settings.`).option("--settled-at <value>", `Date the invoice was fully paid.`).option("--properties <value>", `Key/value pairs to store any metadata useful in your context.`).requiredOption("--line-items <value>", `line_items`).option("--transactions <value>", `transactions`).option("--coupons <value>", `coupons`).addHelpText("after", `
40241
+ `).option("--payment-method-id <value>", `ID of the default payment method used to pay the invoice. Transactions related to the invoice may use different payment methods.`).option("--bank-account-id <value>", `ID of the bank account displayed on the invoice. Transactions related to the invoice may use different bank accounts.`).option("--subscription-id <value>", `ID of the subscription related to the invoice.`).option("--emitted-at <value>", `Issue date of the invoice.`).option("--due-at <value>", `Due date of the invoice. Computed from the issue date and the payment delay configured in your settings.`).option("--settled-at <value>", `Date the invoice was fully paid.`).option("--properties <value>", `Key/value pairs to store any metadata useful in your context.`).option("--custom-properties <value>", `Values for custom properties defined for the \`invoice\` entity, keyed by slug.`).requiredOption("--line-items <value>", `line_items`).option("--transactions <value>", `transactions`).option("--coupons <value>", `coupons`).addHelpText("after", `
40176
40242
  Examples:
40177
40243
  hyperline invoices create-invoice --customer-id <customer_id> --line-items <line_items>
40178
40244
  hyperline invoices create-invoice --customer-id <customer_id> --line-items <line_items> --currency <currency> --status <status>
@@ -40225,6 +40291,8 @@ Examples:
40225
40291
  args.settled_at = opts.settledAt;
40226
40292
  if (opts.properties !== void 0)
40227
40293
  args.properties = opts.properties;
40294
+ if (opts.customProperties !== void 0)
40295
+ args.custom_properties = opts.customProperties;
40228
40296
  if (opts.lineItems !== void 0)
40229
40297
  args.line_items = opts.lineItems;
40230
40298
  if (opts.transactions !== void 0)
@@ -40238,10 +40306,15 @@ Examples:
40238
40306
  queryParamKeys: []
40239
40307
  });
40240
40308
  });
40241
- resource.command("create-credit-note").description(`Create a credit note for an existing invoice by ID. Credit notes partially or fully reverse an invoice amount.`).requiredOption("--id <value>", `id parameter`).option("--amount-including-tax <number>", `Amount of the credit note. If not specified, the amount will be computed from the original invoice.`).option("--status <value>", `Status of the credit note.
40309
+ resource.command("create-credit-note").description(`Create a credit note for an existing invoice by ID. Credit notes partially or fully reverse an invoice amount. Optionally trigger a refund via wallet, original payment method, or external settlement.`).requiredOption("--id <value>", `id parameter`).option("--amount-including-tax <number>", `Amount of the credit note. If not specified, the amount will be computed from the original invoice.`).option("--status <value>", `Status of the credit note.
40242
40310
 
40243
40311
  - \`to_pay\`: Credit note is awaiting payment.
40244
40312
  - \`draft\`: Credit note is in draft mode (not finalized yet).
40313
+ `).option("--trigger-refund", `Whether to trigger a refund for the credit note amount. Defaults to \`false\`. When \`true\`, the refund is issued using \`refund_method\`.`).option("--refund-method <value>", `How the refund should be settled. Only used when \`trigger_refund\` is \`true\`. Defaults to \`original_payment_method\`.
40314
+
40315
+ - \`wallet\`: Credit the customer's wallet with the refunded amount.
40316
+ - \`original_payment_method\`: Refund to the payment method used on the original invoice.
40317
+ - \`external\`: Mark the refund as settled externally (no automatic transfer).
40245
40318
  `).addHelpText("after", `
40246
40319
  Examples:
40247
40320
  hyperline invoices create-credit-note --id <id>
@@ -40257,8 +40330,12 @@ Examples:
40257
40330
  args.id = opts.id;
40258
40331
  if (opts.status !== void 0)
40259
40332
  args.status = opts.status;
40333
+ if (opts.refundMethod !== void 0)
40334
+ args.refund_method = opts.refundMethod;
40260
40335
  if (opts.amountIncludingTax !== void 0)
40261
40336
  args.amount_including_tax = Number(opts.amountIncludingTax);
40337
+ if (opts.triggerRefund !== void 0)
40338
+ args.trigger_refund = true;
40262
40339
  await ctx.execute({
40263
40340
  method: "POST",
40264
40341
  path: "/v1/invoices/{id}/credit-notes",
@@ -40370,7 +40447,7 @@ Examples:
40370
40447
  queryParamKeys: []
40371
40448
  });
40372
40449
  });
40373
- resource.command("get").description(`Retrieve full details of an invoice by ID including line items, transactions, customer info, and billing metadata.`).requiredOption("--id <value>", `id parameter`).addHelpText("after", `
40450
+ resource.command("get").description(`Retrieve the details of an invoice by ID including line items, transactions, customer info, and billing metadata.`).requiredOption("--id <value>", `id parameter`).addHelpText("after", `
40374
40451
  Examples:
40375
40452
  hyperline invoices get --id <id>`).action(async (opts) => {
40376
40453
  const ctx = resource.parent?.opts()._ctx;
@@ -40383,12 +40460,12 @@ Examples:
40383
40460
  args.id = opts.id;
40384
40461
  await ctx.execute({
40385
40462
  method: "GET",
40386
- path: "/v1/invoices/{id}",
40463
+ path: "/v2/invoices/{id}",
40387
40464
  args,
40388
40465
  queryParamKeys: []
40389
40466
  });
40390
40467
  });
40391
- resource.command("update").description(`Update a draft or grace_period invoice. Allows modifying line items, dates, and metadata before finalization.`).requiredOption("--id <value>", `id parameter`).option("--type <value>", `Type of the invoice.
40468
+ resource.command("update").description(`Update an invoice. Draft/grace_period allow modifying line items, dates, and metadata before finalization. Finalized invoices are restricted to metadata (paid: custom_note; uncollectible: properties/custom_note/custom_properties).`).requiredOption("--id <value>", `id parameter`).option("--type <value>", `Type of the invoice.
40392
40469
 
40393
40470
  - \`invoice\`: Legal invoice to be paid by your customer.
40394
40471
  - \`credit_note\`: Legal credit note cancelling an invoice and refunding your customer.
@@ -40397,7 +40474,7 @@ Examples:
40397
40474
 
40398
40475
  - \`auto\`: Tax is automatically computed and applied.
40399
40476
  - \`not_eligible\`: Tax collection is disabled for the invoice.
40400
- `).option("--line-items <value>", `line_items`).option("--coupons <value>", `coupons`).option("--payment-method-type <value>", `payment_method_type`).option("--payment-method-id <value>", `ID of the default payment method used to pay the invoice. Transactions related to the invoice may use different payment methods.`).option("--bank-account-id <value>", `ID of the bank account displayed on the invoice. Transactions related to the invoice may use different bank accounts.`).option("--properties <value>", `Key/value pairs to store any metadata useful in your context.`).option("--customer <value>", `Override customer details on the invoice. Only allowed for draft or grace period invoices.`).addHelpText("after", `
40477
+ `).option("--line-items <value>", `line_items`).option("--coupons <value>", `coupons`).option("--payment-method-type <value>", `payment_method_type`).option("--payment-method-id <value>", `ID of the default payment method used to pay the invoice. Transactions related to the invoice may use different payment methods.`).option("--bank-account-id <value>", `ID of the bank account displayed on the invoice. Transactions related to the invoice may use different bank accounts.`).option("--properties <value>", `Key/value pairs to store any metadata useful in your context.`).option("--custom-properties <value>", `Values for custom properties defined for the \`invoice\` entity, keyed by slug.`).option("--customer <value>", `Override customer details on the invoice. Only allowed for draft or grace period invoices.`).addHelpText("after", `
40401
40478
  Examples:
40402
40479
  hyperline invoices update --id <id>
40403
40480
  hyperline invoices update --id <id> --type <type> --document-name <document_name>
@@ -40438,6 +40515,8 @@ Examples:
40438
40515
  args.bank_account_id = opts.bankAccountId;
40439
40516
  if (opts.properties !== void 0)
40440
40517
  args.properties = opts.properties;
40518
+ if (opts.customProperties !== void 0)
40519
+ args.custom_properties = opts.customProperties;
40441
40520
  if (opts.customer !== void 0)
40442
40521
  args.customer = opts.customer;
40443
40522
  await ctx.execute({
@@ -40558,7 +40637,7 @@ Examples:
40558
40637
  queryParamKeys: []
40559
40638
  });
40560
40639
  });
40561
- resource.command("delete-invoice-transaction").description(`Delete a scheduled transaction from an invoice. Only applies to transactions that haven't been processed yet.`).requiredOption("--id <value>", `id parameter`).requiredOption("--transaction-id <value>", `transactionId parameter`).option("--yes", "Skip confirmation").addHelpText("after", `
40640
+ resource.command("delete-invoice-transaction").description(`Delete a scheduled transaction or wallet debit from an invoice.`).requiredOption("--id <value>", `id parameter`).requiredOption("--transaction-id <value>", `transactionId parameter`).option("--yes", "Skip confirmation").addHelpText("after", `
40562
40641
  Examples:
40563
40642
  hyperline invoices-transactions delete-invoice-transaction --id <id> --transaction-id <transactionId>
40564
40643
  hyperline invoices-transactions delete-invoice-transaction --id <id> --transaction-id <transactionId> --output json`).action(async (opts) => {
@@ -40630,7 +40709,7 @@ Examples:
40630
40709
  queryParamKeys: []
40631
40710
  });
40632
40711
  });
40633
- resource.command("create-invoicing-entity").description(`Create a new invoicing entity with company details, address, and tax configuration. Used as the sender on invoices.`).option("--is-default", `Flag to indicate if this is the default invoicing entity. If true, it will switch the other existing invoicing entities to non-default.`).requiredOption("--name <value>", `The name of the invoicing entity.`).option("--trade-name <value>", `The trade name of the invoicing entity.`).option("--timezone <value>", `The timezone the invoicing entity operates in.`).option("--language <value>", `The default language of the invoicing entity.`).option("--registration-number <value>", `The registration number of the invoicing entity.`).option("--tax-id <value>", `The tax identification number of the invoicing entity.`).option("--billing-email <value>", `The billing email address for the invoicing entity.`).option("--address-line1 <value>", `The first line of the address for the invoicing entity.`).option("--address-line2 <value>", `The second line of the address for the invoicing entity.`).option("--zip-code <value>", `The postal code for the invoicing entity's address.`).option("--state <value>", `The state or province of the invoicing entity.`).option("--city <value>", `The city of the invoicing entity.`).requiredOption("--country <value>", `The country in which the invoicing entity is registered.`).requiredOption("--currency <value>", `The currency code that the invoicing entity operates in.`).requiredOption("--accounting-currency <value>", `The currency used for accounting purposes.`).option("--invoice-number-pattern <value>", `The pattern used for generating invoice numbers. Available dynamic elements: number {number} (mandatory), year {YYYY}, month {MM} and day {DD}.`).option("--credit-note-number-pattern <value>", `The pattern used for generating credit note numbers. Available dynamic elements: number {number} (mandatory), year {YYYY}, month {MM} and day {DD}.`).option("--document-number-pattern <value>", `The pattern used for generating document numbers. Available dynamic elements: number {number} (mandatory), year {YYYY}, month {MM} and day {DD}.`).option("--next-invoice-number <number>", `The next invoice number to be used.`).option("--next-credit-note-number <number>", `The next credit note number to be used.`).option("--next-document-number <number>", `The next document number to be used.`).option("--default-payment-delay <number>", `The default payment term in days.`).option("--invoice-grace-period-duration <number>", `The grace period duration in days.`).option("--invoice-payment-initiation-delay <number>", `The payment initiation delay in days for the invoices.`).option("--document-payment-initiation-delay <number>", `The payment initiation delay in days for the custom documents.`).option("--invoice-late-fees <value>", `The late fees applicable to the invoices.`).option("--invoice-footer <value>", `The footer text to be used in invoices.`).option("--document-footer <value>", `The footer text to be used in documents. If not specified, the invoice footer will be used.`).option("--quote-footer <value>", `The footer text to be used in quotes.`).option("--logo-url <value>", `URL of the logo to be used in invoices.`).option("--favicon-url <value>", `URL of the logo to be used as favicon.`).option("--brand-color <value>", `Brand color to be used in invoices (hexadecimal color code).`).option("--forced-customer-type <value>", `Forces all customers created under this invoicing entity to have this type. Set to null to allow users to choose.`).addHelpText("after", `
40712
+ resource.command("create-invoicing-entity").description(`Create a new invoicing entity with company details, address, and tax configuration. Used as the sender on invoices.`).option("--is-default", `Flag to indicate if this is the default invoicing entity. If true, it will switch the other existing invoicing entities to non-default.`).requiredOption("--name <value>", `The name of the invoicing entity.`).option("--trade-name <value>", `The trade name of the invoicing entity.`).option("--timezone <value>", `The timezone the invoicing entity operates in.`).option("--language <value>", `The default language of the invoicing entity.`).option("--registration-number <value>", `The registration number of the invoicing entity.`).option("--tax-id <value>", `The tax identification number of the invoicing entity.`).option("--billing-email <value>", `The billing email address for the invoicing entity.`).option("--address-line1 <value>", `The first line of the address for the invoicing entity.`).option("--address-line2 <value>", `The second line of the address for the invoicing entity.`).option("--zip-code <value>", `The postal code for the invoicing entity's address.`).option("--state <value>", `The state or province of the invoicing entity.`).option("--city <value>", `The city of the invoicing entity.`).requiredOption("--country <value>", `The country in which the invoicing entity is registered.`).requiredOption("--currency <value>", `The currency code that the invoicing entity operates in.`).requiredOption("--accounting-currency <value>", `The currency used for accounting purposes.`).option("--invoice-number-pattern <value>", `The pattern used for generating invoice numbers. Available dynamic elements: number {number} (mandatory), year {YYYY}, month {MM} and day {DD}.`).option("--credit-note-number-pattern <value>", `The pattern used for generating credit note numbers. Available dynamic elements: number {number} (mandatory), year {YYYY}, month {MM} and day {DD}.`).option("--document-number-pattern <value>", `The pattern used for generating document numbers. Available dynamic elements: number {number} (mandatory), year {YYYY}, month {MM} and day {DD}.`).option("--next-invoice-number <number>", `The next invoice number to be used.`).option("--next-credit-note-number <number>", `The next credit note number to be used.`).option("--next-document-number <number>", `The next document number to be used.`).option("--default-payment-delay <number>", `The default payment term in days.`).option("--invoice-grace-period-duration <number>", `The grace period duration in days.`).option("--invoice-payment-initiation-delay <number>", `The payment initiation delay in days for the invoices.`).option("--document-payment-initiation-delay <number>", `The payment initiation delay in days for the custom documents.`).option("--invoice-late-fees <value>", `The late fees applicable to the invoices.`).option("--invoice-footer <value>", `The footer text to be used in invoices.`).option("--document-footer <value>", `The footer text to be used in documents. If not specified, the invoice footer will be used.`).option("--quote-footer <value>", `The footer text to be used in quotes.`).option("--logo-url <value>", `URL of the logo to be used in invoices.`).option("--favicon-url <value>", `URL of the logo to be used as favicon.`).option("--brand-color <value>", `Brand color to be used in invoices (hexadecimal color code).`).option("--forced-customer-type <value>", `Forces all customers created under this invoicing entity to have this type. Set to null to allow users to choose.`).option("--credit-note-wallet-refund-enabled", `When enabled, credit note refunds default to the customer's wallet for invoices under this invoicing entity. The default applies only when \`refund_method\` is omitted on \`POST /v1/invoices/{id}/credit-notes\`; an explicit \`refund_method\` always wins. Requires wallets to be enabled at the workspace level.`).addHelpText("after", `
40634
40713
  Examples:
40635
40714
  hyperline invoicing-entities create-invoicing-entity --name <name> --country <country> --currency <currency> --accounting-currency <accounting_currency>
40636
40715
  hyperline invoicing-entities create-invoicing-entity --name <name> --country <country> --currency <currency> --accounting-currency <accounting_currency> --is-default --trade-name <trade_name>
@@ -40709,6 +40788,8 @@ Examples:
40709
40788
  args.document_payment_initiation_delay = Number(opts.documentPaymentInitiationDelay);
40710
40789
  if (opts.isDefault !== void 0)
40711
40790
  args.is_default = true;
40791
+ if (opts.creditNoteWalletRefundEnabled !== void 0)
40792
+ args.credit_note_wallet_refund_enabled = true;
40712
40793
  await ctx.execute({
40713
40794
  method: "POST",
40714
40795
  path: "/v1/invoicing-entities",
@@ -40716,7 +40797,7 @@ Examples:
40716
40797
  queryParamKeys: []
40717
40798
  });
40718
40799
  });
40719
- resource.command("update-invoicing-entity").description(`Update an existing invoicing entity's details (address, tax ID, branding, etc.).`).requiredOption("--id <value>", `id parameter`).option("--name <value>", `The name of the invoicing entity.`).option("--registration-number <value>", `The registration number of the invoicing entity.`).option("--tax-id <value>", `The tax identification number of the invoicing entity.`).option("--billing-email <value>", `The billing email address for the invoicing entity.`).option("--timezone <value>", `The timezone the invoicing entity operates in.`).option("--language <value>", `The default language of the invoicing entity.`).option("--is-default", `Flag to indicate if this is the default invoicing entity. If true, it will switch the other existing invoicing entities to non-default.`).option("--address-line1 <value>", `The first line of the address for the invoicing entity.`).option("--address-line2 <value>", `The second line of the address for the invoicing entity.`).option("--zip-code <value>", `The postal code for the invoicing entity's address.`).option("--state <value>", `The state or province of the invoicing entity.`).option("--city <value>", `The city of the invoicing entity.`).option("--country <value>", `The country in which the invoicing entity is registered.`).option("--currency <value>", `The currency code that the invoicing entity operates in.`).option("--accounting-currency <value>", `The currency used for accounting purposes.`).option("--invoice-number-pattern <value>", `The pattern used for generating invoice numbers. Available dynamic elements: number {number} (mandatory), year {YYYY}, month {MM} and day {DD}.`).option("--credit-note-number-pattern <value>", `The pattern used for generating credit note numbers. Available dynamic elements: number {number} (mandatory), year {YYYY}, month {MM} and day {DD}.`).option("--document-number-pattern <value>", `The pattern used for generating document numbers. Available dynamic elements: number {number} (mandatory), year {YYYY}, month {MM} and day {DD}.`).option("--default-payment-delay <number>", `The default payment term in days.`).option("--invoice-grace-period-duration <number>", `The grace period duration in days.`).option("--invoice-payment-initiation-delay <number>", `The payment initiation delay in days for the invoices.`).option("--document-payment-initiation-delay <number>", `The payment initiation delay in days for the custom documents.`).option("--invoice-late-fees <value>", `The late fees applicable to the invoices.`).option("--invoice-footer <value>", `The footer text to be used in invoices.`).option("--document-footer <value>", `The footer text to be used in documents. If not specified, the invoice footer will be used.`).option("--logo-url <value>", `URL of the logo to be used in invoices.`).option("--favicon-url <value>", `URL of the logo to be used as favicon.`).option("--brand-color <value>", `Brand color to be used in invoices (hexadecimal color code).`).option("--forced-customer-type <value>", `Forces all customers created under this invoicing entity to have this type. Set to null to allow users to choose.`).addHelpText("after", `
40800
+ resource.command("update-invoicing-entity").description(`Update an existing invoicing entity's details (address, tax ID, branding, etc.).`).requiredOption("--id <value>", `id parameter`).option("--name <value>", `The name of the invoicing entity.`).option("--registration-number <value>", `The registration number of the invoicing entity.`).option("--tax-id <value>", `The tax identification number of the invoicing entity.`).option("--billing-email <value>", `The billing email address for the invoicing entity.`).option("--timezone <value>", `The timezone the invoicing entity operates in.`).option("--language <value>", `The default language of the invoicing entity.`).option("--is-default", `Flag to indicate if this is the default invoicing entity. If true, it will switch the other existing invoicing entities to non-default.`).option("--address-line1 <value>", `The first line of the address for the invoicing entity.`).option("--address-line2 <value>", `The second line of the address for the invoicing entity.`).option("--zip-code <value>", `The postal code for the invoicing entity's address.`).option("--state <value>", `The state or province of the invoicing entity.`).option("--city <value>", `The city of the invoicing entity.`).option("--country <value>", `The country in which the invoicing entity is registered.`).option("--currency <value>", `The currency code that the invoicing entity operates in.`).option("--accounting-currency <value>", `The currency used for accounting purposes.`).option("--invoice-number-pattern <value>", `The pattern used for generating invoice numbers. Available dynamic elements: number {number} (mandatory), year {YYYY}, month {MM} and day {DD}.`).option("--credit-note-number-pattern <value>", `The pattern used for generating credit note numbers. Available dynamic elements: number {number} (mandatory), year {YYYY}, month {MM} and day {DD}.`).option("--document-number-pattern <value>", `The pattern used for generating document numbers. Available dynamic elements: number {number} (mandatory), year {YYYY}, month {MM} and day {DD}.`).option("--default-payment-delay <number>", `The default payment term in days.`).option("--invoice-grace-period-duration <number>", `The grace period duration in days.`).option("--invoice-payment-initiation-delay <number>", `The payment initiation delay in days for the invoices.`).option("--document-payment-initiation-delay <number>", `The payment initiation delay in days for the custom documents.`).option("--invoice-late-fees <value>", `The late fees applicable to the invoices.`).option("--invoice-footer <value>", `The footer text to be used in invoices.`).option("--document-footer <value>", `The footer text to be used in documents. If not specified, the invoice footer will be used.`).option("--logo-url <value>", `URL of the logo to be used in invoices.`).option("--favicon-url <value>", `URL of the logo to be used as favicon.`).option("--brand-color <value>", `Brand color to be used in invoices (hexadecimal color code).`).option("--forced-customer-type <value>", `Forces all customers created under this invoicing entity to have this type. Set to null to allow users to choose.`).option("--credit-note-wallet-refund-enabled", `When enabled, credit note refunds default to the customer's wallet for invoices under this invoicing entity. The default applies only when \`refund_method\` is omitted on \`POST /v1/invoices/{id}/credit-notes\`; an explicit \`refund_method\` always wins. Requires wallets to be enabled at the workspace level.`).addHelpText("after", `
40720
40801
  Examples:
40721
40802
  hyperline invoicing-entities update-invoicing-entity --id <id>
40722
40803
  hyperline invoicing-entities update-invoicing-entity --id <id> --name <name> --registration-number <registration_number>
@@ -40787,6 +40868,8 @@ Examples:
40787
40868
  args.document_payment_initiation_delay = Number(opts.documentPaymentInitiationDelay);
40788
40869
  if (opts.isDefault !== void 0)
40789
40870
  args.is_default = true;
40871
+ if (opts.creditNoteWalletRefundEnabled !== void 0)
40872
+ args.credit_note_wallet_refund_enabled = true;
40790
40873
  await ctx.execute({
40791
40874
  method: "PUT",
40792
40875
  path: "/v1/invoicing-entities/{id}",
@@ -41355,18 +41438,18 @@ Examples:
41355
41438
  // build/commands/generated/quotes.js
41356
41439
  function registerQuotesCommands(parent) {
41357
41440
  const resource = parent.command("quotes").description("Manage quotes");
41358
- resource.command("create").description(`Create a new quote for a customer with line items, products, and optional file attachments. Quotes can be sent for signature and converted to subscriptions.`).option("--status <value>", `
41441
+ resource.command("create").description(`Create a new quote for a customer. Use \`subscription\` (or \`template_id\`) for subscription quotes; use \`invoice\` for one-off quotes backed by a draft invoice with line items. Quotes can be sent for signature and converted to subscriptions or one-off invoices. When creating from a quote template, do not combine \`template_id\` with subscription overrides for dates, contract terms, products, phases, coupons, discounts, prices, or seats in this call: first create the quote from \`template_id\` so template terms and contract documents are copied, then call \`update_quote\` with the subscription payload.`).option("--status <value>", `
41359
41442
  Quote status.
41360
41443
 
41361
41444
  - \`draft\`: The quote is a draft.
41362
41445
  - \`approved\`: The quote is approved and ready to be sent to the customer.
41363
41446
  - \`pending_signature\`: The quote is awaiting the customer's signature.
41364
- `).option("--owner-email <value>", `Email address of the Hyperline user acting as the quote owner. If not specified, the Hyperline account owner will be assigned.`).requiredOption("--customer-id <value>", `ID of the customer.`).option("--invoicing-entity-id <value>", `ID of the invoicing entity attached to the quote.`).option("--comments <value>", `Custom comments displayed on the quote.`).option("--terms <value>", `Custom quotation terms.`).option("--amount <number>", `Estimated contract value. If not specified, automatically computed from the subscription configuration.`).option("--collect-payment-details <value>", `Collect customer payment method mandate during signature flow or not.`).option("--collect-custom-property-ids <value>", `IDs of the customer custom properties required to be filled during the signature flow.`).option("--require-tax-id <value>", `Require the customer to provide a tax ID during the signature flow.`).option("--display-quote-value <value>", `Display the total quote value on the quote.`).option("--display-quote-value-with-tax <value>", `Display the total quote value including tax on the quote. Only applies to \`one_off\` quotes.`).option("--display-taxes <value>", `Display tax breakdown on the quote.`).option("--display-price-tiers <value>", `Controls which price tiers are displayed on the quote.
41447
+ `).option("--owner-email <value>", `Email address of the Hyperline user acting as the quote owner. If not specified, the Hyperline account owner will be assigned.`).requiredOption("--customer-id <value>", `ID of the customer.`).option("--invoicing-entity-id <value>", `ID of the invoicing entity attached to the quote.`).option("--comments <value>", `Custom comments displayed on the quote.`).option("--terms <value>", `Custom quotation terms.`).option("--amount <number>", `Estimated contract value. For subscription quotes, defaults to the computed subscription value if not specified. For one-off quotes, this field is ignored \u2014 the amount is always derived from the linked invoice's \`amount_excluding_tax\`.`).option("--collect-payment-details <value>", `Collect customer payment method mandate during signature flow or not.`).option("--collect-custom-property-ids <value>", `IDs of the customer custom properties required to be filled during the signature flow.`).option("--contract-clause-ids <value>", `IDs of the contract clauses used in the quote terms.`).option("--require-tax-id <value>", `Require the customer to provide a tax ID during the signature flow.`).option("--display-quote-value <value>", `Display the total quote value on the quote.`).option("--display-quote-value-with-tax <value>", `Display the total quote value including tax on the quote. Only applies to \`one_off\` quotes.`).option("--display-taxes <value>", `Display tax breakdown on the quote.`).option("--display-price-tiers <value>", `Controls which price tiers are displayed on the quote.
41365
41448
 
41366
41449
  - \`all\`: Display all pricing tiers.
41367
41450
  - \`matching\`: Only display the tiers used to compute the price based on quantity.
41368
41451
  - \`none\`: Hide all pricing tiers.
41369
- `).option("--display-phase-value <value>", `Display per-phase value breakdown on the quote.`).option("--display-first-invoice-amount <value>", `Display the first invoice amount on the quote.`).option("--display-documents-in-preview <value>", `Display attached documents in the quote preview.`).option("--display-subscription-on-update <value>", `Display subscription details on subscription update quotes.`).option("--template-id <value>", `ID of the quote template. If not specified, a subscription configuration must be defined.`).option("--expires-at <value>", `Quote expiration date. UTC date time string in the [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format.`).option("--subscription <value>", `Subscription configuration constituting the quote.`).addHelpText("after", `
41452
+ `).option("--display-phase-value <value>", `Display per-phase value breakdown on the quote.`).option("--display-first-invoice-amount <value>", `Display the first invoice amount on the quote.`).option("--display-documents-in-preview <value>", `Display attached documents in the quote preview.`).option("--display-subscription-on-update <value>", `Display subscription details on subscription update quotes.`).option("--generate-draft-invoices <value>", `When \`true\`, the invoice issued after signature stays in \`draft\` status instead of being emitted for payment. Use this when you want to review the final invoice manually before sending it. Defaults to \`false\`.`).option("--template-id <value>", `ID of the quote template. If not specified, a subscription configuration or an \`invoice\` payload must be defined.`).option("--expires-at <value>", `Quote expiration date. UTC date time string in the [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format.`).option("--subscription <value>", `Subscription configuration constituting the quote.`).option("--invoice <value>", `Invoice configuration constituting the one-off quote. When provided, a draft invoice is created and linked to the quote. Cannot be combined with \`subscription\` or \`template_id\`.`).addHelpText("after", `
41370
41453
  Examples:
41371
41454
  hyperline quotes create --customer-id <customer_id>
41372
41455
  hyperline quotes create --customer-id <customer_id> --status <status> --owner-email <owner_email>
@@ -41393,6 +41476,8 @@ Examples:
41393
41476
  args.collect_payment_details = opts.collectPaymentDetails;
41394
41477
  if (opts.collectCustomPropertyIds !== void 0)
41395
41478
  args.collect_custom_property_ids = opts.collectCustomPropertyIds;
41479
+ if (opts.contractClauseIds !== void 0)
41480
+ args.contract_clause_ids = opts.contractClauseIds;
41396
41481
  if (opts.requireTaxId !== void 0)
41397
41482
  args.require_tax_id = opts.requireTaxId;
41398
41483
  if (opts.displayQuoteValue !== void 0)
@@ -41411,12 +41496,16 @@ Examples:
41411
41496
  args.display_documents_in_preview = opts.displayDocumentsInPreview;
41412
41497
  if (opts.displaySubscriptionOnUpdate !== void 0)
41413
41498
  args.display_subscription_on_update = opts.displaySubscriptionOnUpdate;
41499
+ if (opts.generateDraftInvoices !== void 0)
41500
+ args.generate_draft_invoices = opts.generateDraftInvoices;
41414
41501
  if (opts.templateId !== void 0)
41415
41502
  args.template_id = opts.templateId;
41416
41503
  if (opts.expiresAt !== void 0)
41417
41504
  args.expires_at = opts.expiresAt;
41418
41505
  if (opts.subscription !== void 0)
41419
41506
  args.subscription = opts.subscription;
41507
+ if (opts.invoice !== void 0)
41508
+ args.invoice = opts.invoice;
41420
41509
  if (opts.amount !== void 0)
41421
41510
  args.amount = Number(opts.amount);
41422
41511
  await ctx.execute({
@@ -41645,6 +41734,71 @@ Examples:
41645
41734
  queryParamKeys: []
41646
41735
  });
41647
41736
  });
41737
+ resource.command("update").description(`Update quote-level fields before a quote is finalized. On draft quotes, pass \`subscription\` to create or replace the draft subscription configuration, or pass \`invoice\` on a one-off quote to replace the linked draft invoice. For quotes created from \`template_id\`, use this tool for subscription overrides such as dates, contract terms, products, phases, coupons, discounts, prices, seats, and subscription custom properties. Omit \`terms\`, \`comments\`, and \`contract_clause_ids\` unless deliberately overriding template content.`).requiredOption("--id <value>", `id parameter`).option("--owner-email <value>", `Email address of the Hyperline user acting as the quote owner.`).option("--comments <value>", `Custom comments displayed on the quote.`).option("--terms <value>", `Custom quotation terms.`).option("--amount <number>", `Estimated contract value. Set to \`null\` to clear the manually set value.`).option("--collect-payment-details <value>", `Collect customer payment method mandate during signature flow or not.`).option("--collect-custom-property-ids <value>", `IDs of the customer custom properties required to be filled during the signature flow.`).option("--contract-clause-ids <value>", `IDs of the contract clauses used in the quote terms.`).option("--require-tax-id <value>", `Require the customer to provide a tax ID during the signature flow.`).option("--display-quote-value <value>", `Display the total quote value on the quote.`).option("--display-quote-value-with-tax <value>", `Display the total quote value including tax on the quote. Only applies to \`one_off\` quotes.`).option("--display-taxes <value>", `Display tax breakdown on the quote.`).option("--display-price-tiers <value>", `Controls which price tiers are displayed on the quote.
41738
+
41739
+ - \`all\`: Display all pricing tiers.
41740
+ - \`matching\`: Only display the tiers used to compute the price based on quantity.
41741
+ - \`none\`: Hide all pricing tiers.
41742
+ `).option("--display-phase-value <value>", `Display per-phase value breakdown on the quote.`).option("--display-first-invoice-amount <value>", `Display the first invoice amount on the quote.`).option("--display-documents-in-preview <value>", `Display attached documents in the quote preview.`).option("--display-subscription-on-update <value>", `Display subscription details on subscription update quotes.`).option("--generate-draft-invoices <value>", `When \`true\`, the invoice issued after signature stays in \`draft\` status instead of being emitted for payment. Use this when you want to review the final invoice manually before sending it. Defaults to \`false\`.`).option("--expires-at <value>", `Quote expiration date. UTC date time string in the [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format. Set to \`null\` to clear the expiration.`).option("--subscription <value>", `Subscription configuration constituting the quote. When provided on a draft quote, it creates or replaces the draft subscription attached to the quote.`).option("--invoice <value>", `Invoice configuration constituting the one-off quote. When provided on a draft one-off quote, it deletes the previous draft invoice and creates a fresh one linked to the quote. \`invoice.invoicing_entity_id\` is ignored on update \u2014 the quote's existing invoicing entity is reused.`).addHelpText("after", `
41743
+ Examples:
41744
+ hyperline quotes update --id <id>
41745
+ hyperline quotes update --id <id> --owner-email <owner_email> --comments <comments>
41746
+ hyperline quotes update --id <id> --output json`).action(async (opts) => {
41747
+ const ctx = resource.parent?.opts()._ctx;
41748
+ if (!ctx) {
41749
+ process.stderr.write("Error: Not authenticated\n");
41750
+ process.exit(1);
41751
+ }
41752
+ const args = {};
41753
+ if (opts.id !== void 0)
41754
+ args.id = opts.id;
41755
+ if (opts.ownerEmail !== void 0)
41756
+ args.owner_email = opts.ownerEmail;
41757
+ if (opts.comments !== void 0)
41758
+ args.comments = opts.comments;
41759
+ if (opts.terms !== void 0)
41760
+ args.terms = opts.terms;
41761
+ if (opts.collectPaymentDetails !== void 0)
41762
+ args.collect_payment_details = opts.collectPaymentDetails;
41763
+ if (opts.collectCustomPropertyIds !== void 0)
41764
+ args.collect_custom_property_ids = opts.collectCustomPropertyIds;
41765
+ if (opts.contractClauseIds !== void 0)
41766
+ args.contract_clause_ids = opts.contractClauseIds;
41767
+ if (opts.requireTaxId !== void 0)
41768
+ args.require_tax_id = opts.requireTaxId;
41769
+ if (opts.displayQuoteValue !== void 0)
41770
+ args.display_quote_value = opts.displayQuoteValue;
41771
+ if (opts.displayQuoteValueWithTax !== void 0)
41772
+ args.display_quote_value_with_tax = opts.displayQuoteValueWithTax;
41773
+ if (opts.displayTaxes !== void 0)
41774
+ args.display_taxes = opts.displayTaxes;
41775
+ if (opts.displayPriceTiers !== void 0)
41776
+ args.display_price_tiers = opts.displayPriceTiers;
41777
+ if (opts.displayPhaseValue !== void 0)
41778
+ args.display_phase_value = opts.displayPhaseValue;
41779
+ if (opts.displayFirstInvoiceAmount !== void 0)
41780
+ args.display_first_invoice_amount = opts.displayFirstInvoiceAmount;
41781
+ if (opts.displayDocumentsInPreview !== void 0)
41782
+ args.display_documents_in_preview = opts.displayDocumentsInPreview;
41783
+ if (opts.displaySubscriptionOnUpdate !== void 0)
41784
+ args.display_subscription_on_update = opts.displaySubscriptionOnUpdate;
41785
+ if (opts.generateDraftInvoices !== void 0)
41786
+ args.generate_draft_invoices = opts.generateDraftInvoices;
41787
+ if (opts.expiresAt !== void 0)
41788
+ args.expires_at = opts.expiresAt;
41789
+ if (opts.subscription !== void 0)
41790
+ args.subscription = opts.subscription;
41791
+ if (opts.invoice !== void 0)
41792
+ args.invoice = opts.invoice;
41793
+ if (opts.amount !== void 0)
41794
+ args.amount = Number(opts.amount);
41795
+ await ctx.execute({
41796
+ method: "PATCH",
41797
+ path: "/v1/quotes/{id}",
41798
+ args,
41799
+ queryParamKeys: []
41800
+ });
41801
+ });
41648
41802
  resource.command("download").description(`Download the PDF of a quote. Supports locale parameter for localization.`).requiredOption("--id <value>", `id parameter`).option("--locale <value>", `locale`).addHelpText("after", `
41649
41803
  Examples:
41650
41804
  hyperline quotes download --id <id>
@@ -41685,6 +41839,25 @@ Examples:
41685
41839
  queryParamKeys: []
41686
41840
  });
41687
41841
  });
41842
+ resource.command("finalize").description(`Finalize a draft quote. The quote is submitted for approval when approval is required, otherwise it becomes approved and ready to be sent for signature.`).requiredOption("--id <value>", `id parameter`).addHelpText("after", `
41843
+ Examples:
41844
+ hyperline quotes finalize --id <id>
41845
+ hyperline quotes finalize --id <id> --output json`).action(async (opts) => {
41846
+ const ctx = resource.parent?.opts()._ctx;
41847
+ if (!ctx) {
41848
+ process.stderr.write("Error: Not authenticated\n");
41849
+ process.exit(1);
41850
+ }
41851
+ const args = {};
41852
+ if (opts.id !== void 0)
41853
+ args.id = opts.id;
41854
+ await ctx.execute({
41855
+ method: "POST",
41856
+ path: "/v1/quotes/{id}/finalize",
41857
+ args,
41858
+ queryParamKeys: []
41859
+ });
41860
+ });
41688
41861
  resource.command("send").description(`Send a quote by email for customer signature. Requires the quote to be approved first.`).requiredOption("--id <value>", `id parameter`).requiredOption("--email <value>", `Email address to which the quote will be sent for signature.`).option("--message <value>", `Custom message used in the email content.`).addHelpText("after", `
41689
41862
  Examples:
41690
41863
  hyperline quotes send --id <id> --email <email>
@@ -41792,10 +41965,132 @@ Examples:
41792
41965
  });
41793
41966
  }
41794
41967
 
41968
+ // build/commands/generated/quotes-templates.js
41969
+ function registerQuotes_TemplatesCommands(parent) {
41970
+ const resource = parent.command("quotes-templates").description("Manage quotes > templates");
41971
+ resource.command("list-quote-templates").description(`List quote templates with pagination and optional filters for id, name, subscription_template_id, and search. Use template IDs to create quotes from reusable quote defaults.`).option("--take <number>", `take`).option("--skip <number>", `skip`).option("--id <value>", `id`).option("--id.not <value>", `id__not`).option("--id.is-null <value>", `id__isNull`).option("--id.is-not-null <value>", `id__isNotNull`).option("--id.equals <value>", `id__equals`).option("--id.contains <value>", `id__contains`).option("--id.starts-with <value>", `id__startsWith`).option("--id.end-with <value>", `id__endWith`).option("--name <value>", `name`).option("--name.not <value>", `name__not`).option("--name.is-null <value>", `name__isNull`).option("--name.is-not-null <value>", `name__isNotNull`).option("--name.equals <value>", `name__equals`).option("--name.contains <value>", `name__contains`).option("--name.starts-with <value>", `name__startsWith`).option("--name.end-with <value>", `name__endWith`).option("--subscription-template-id <value>", `subscription_template_id`).option("--subscription-template-id.not <value>", `subscription_template_id__not`).option("--subscription-template-id.is-null <value>", `subscription_template_id__isNull`).option("--subscription-template-id.is-not-null <value>", `subscription_template_id__isNotNull`).option("--subscription-template-id.equals <value>", `subscription_template_id__equals`).option("--subscription-template-id.contains <value>", `subscription_template_id__contains`).option("--subscription-template-id.starts-with <value>", `subscription_template_id__startsWith`).option("--subscription-template-id.end-with <value>", `subscription_template_id__endWith`).option("--search <value>", `search`).addHelpText("after", `
41972
+ Examples:
41973
+ hyperline quotes-templates list-quote-templates
41974
+ hyperline quotes-templates list-quote-templates --take <take> --id <id>`).action(async (opts) => {
41975
+ const ctx = resource.parent?.opts()._ctx;
41976
+ if (!ctx) {
41977
+ process.stderr.write("Error: Not authenticated\n");
41978
+ process.exit(1);
41979
+ }
41980
+ const args = {};
41981
+ if (opts.id !== void 0)
41982
+ args.id = opts.id;
41983
+ if (opts["id.not"] !== void 0)
41984
+ args.id__not = opts["id.not"];
41985
+ if (opts["id.isNull"] !== void 0)
41986
+ args.id__isNull = opts["id.isNull"];
41987
+ if (opts["id.isNotNull"] !== void 0)
41988
+ args.id__isNotNull = opts["id.isNotNull"];
41989
+ if (opts["id.equals"] !== void 0)
41990
+ args.id__equals = opts["id.equals"];
41991
+ if (opts["id.contains"] !== void 0)
41992
+ args.id__contains = opts["id.contains"];
41993
+ if (opts["id.startsWith"] !== void 0)
41994
+ args.id__startsWith = opts["id.startsWith"];
41995
+ if (opts["id.endWith"] !== void 0)
41996
+ args.id__endWith = opts["id.endWith"];
41997
+ if (opts.name !== void 0)
41998
+ args.name = opts.name;
41999
+ if (opts["name.not"] !== void 0)
42000
+ args.name__not = opts["name.not"];
42001
+ if (opts["name.isNull"] !== void 0)
42002
+ args.name__isNull = opts["name.isNull"];
42003
+ if (opts["name.isNotNull"] !== void 0)
42004
+ args.name__isNotNull = opts["name.isNotNull"];
42005
+ if (opts["name.equals"] !== void 0)
42006
+ args.name__equals = opts["name.equals"];
42007
+ if (opts["name.contains"] !== void 0)
42008
+ args.name__contains = opts["name.contains"];
42009
+ if (opts["name.startsWith"] !== void 0)
42010
+ args.name__startsWith = opts["name.startsWith"];
42011
+ if (opts["name.endWith"] !== void 0)
42012
+ args.name__endWith = opts["name.endWith"];
42013
+ if (opts.subscriptionTemplateId !== void 0)
42014
+ args.subscription_template_id = opts.subscriptionTemplateId;
42015
+ if (opts["subscriptionTemplateId.not"] !== void 0)
42016
+ args.subscription_template_id__not = opts["subscriptionTemplateId.not"];
42017
+ if (opts["subscriptionTemplateId.isNull"] !== void 0)
42018
+ args.subscription_template_id__isNull = opts["subscriptionTemplateId.isNull"];
42019
+ if (opts["subscriptionTemplateId.isNotNull"] !== void 0)
42020
+ args.subscription_template_id__isNotNull = opts["subscriptionTemplateId.isNotNull"];
42021
+ if (opts["subscriptionTemplateId.equals"] !== void 0)
42022
+ args.subscription_template_id__equals = opts["subscriptionTemplateId.equals"];
42023
+ if (opts["subscriptionTemplateId.contains"] !== void 0)
42024
+ args.subscription_template_id__contains = opts["subscriptionTemplateId.contains"];
42025
+ if (opts["subscriptionTemplateId.startsWith"] !== void 0)
42026
+ args.subscription_template_id__startsWith = opts["subscriptionTemplateId.startsWith"];
42027
+ if (opts["subscriptionTemplateId.endWith"] !== void 0)
42028
+ args.subscription_template_id__endWith = opts["subscriptionTemplateId.endWith"];
42029
+ if (opts.search !== void 0)
42030
+ args.search = opts.search;
42031
+ if (opts.take !== void 0)
42032
+ args.take = Number(opts.take);
42033
+ if (opts.skip !== void 0)
42034
+ args.skip = Number(opts.skip);
42035
+ await ctx.execute({
42036
+ method: "GET",
42037
+ path: "/v1/quotes/templates",
42038
+ args,
42039
+ queryParamKeys: [
42040
+ "take",
42041
+ "skip",
42042
+ "id",
42043
+ "id__not",
42044
+ "id__isNull",
42045
+ "id__isNotNull",
42046
+ "id__equals",
42047
+ "id__contains",
42048
+ "id__startsWith",
42049
+ "id__endWith",
42050
+ "name",
42051
+ "name__not",
42052
+ "name__isNull",
42053
+ "name__isNotNull",
42054
+ "name__equals",
42055
+ "name__contains",
42056
+ "name__startsWith",
42057
+ "name__endWith",
42058
+ "subscription_template_id",
42059
+ "subscription_template_id__not",
42060
+ "subscription_template_id__isNull",
42061
+ "subscription_template_id__isNotNull",
42062
+ "subscription_template_id__equals",
42063
+ "subscription_template_id__contains",
42064
+ "subscription_template_id__startsWith",
42065
+ "subscription_template_id__endWith",
42066
+ "search"
42067
+ ]
42068
+ });
42069
+ });
42070
+ resource.command("get-quote-template").description(`Retrieve a quote template by ID with quote defaults, display options, attachments, and linked contract template/clause IDs.`).requiredOption("--id <value>", `id parameter`).addHelpText("after", `
42071
+ Examples:
42072
+ hyperline quotes-templates get-quote-template --id <id>`).action(async (opts) => {
42073
+ const ctx = resource.parent?.opts()._ctx;
42074
+ if (!ctx) {
42075
+ process.stderr.write("Error: Not authenticated\n");
42076
+ process.exit(1);
42077
+ }
42078
+ const args = {};
42079
+ if (opts.id !== void 0)
42080
+ args.id = opts.id;
42081
+ await ctx.execute({
42082
+ method: "GET",
42083
+ path: "/v1/quotes/templates/{id}",
42084
+ args,
42085
+ queryParamKeys: []
42086
+ });
42087
+ });
42088
+ }
42089
+
41795
42090
  // build/commands/generated/subscriptions.js
41796
42091
  function registerSubscriptionsCommands(parent) {
41797
42092
  const resource = parent.command("subscriptions").description("Manage subscriptions");
41798
- resource.command("create-subscription-update").description(`Apply a single update to an existing subscription (e.g. change quantity, add/remove product, modify price).`).requiredOption("--id <value>", `id parameter`).requiredOption("--application-schedule <value>", `application_schedule`).option("--apply-at <value>", `The date when the update should be applied. Required when application_schedule is 'scheduled'.`).requiredOption("--payment-schedule <value>", `payment_schedule`).option("--charge-at <value>", `The date when the resulting subscription update should be charged. Required when payment_schedule is 'custom'. Must be in the future.`).requiredOption("--calculation-method <value>", `calculation_method`).requiredOption("--type <value>", `type`).requiredOption("--payload <value>", `payload`).addHelpText("after", `
42093
+ resource.command("create-subscription-update").description(`Apply a single update to an existing subscription (e.g. change quantity, add/remove product, modify price).`).requiredOption("--id <value>", `id parameter`).requiredOption("--application-schedule <value>", `application_schedule`).option("--apply-at <value>", `The date when the update should be applied. Required when application_schedule is 'scheduled'.`).requiredOption("--payment-schedule <value>", `payment_schedule`).option("--charge-at <value>", `The date when the resulting subscription update should be charged. Required when payment_schedule is 'custom'. Must be in the future.`).requiredOption("--calculation-method <value>", `calculation_method`).option("--precision <value>", `Granularity used to prorate the update amount. Defaults to 'calendar_days' when omitted, prorating on whole calendar days; 'milliseconds' prorates on the exact elapsed time, charging the precise partial period.`).option("--refund-method <value>", `Override the refund destination when the update generates a refund credit note (e.g. seat reduction). When omitted, falls back to the invoicing entity's \`creditNoteWalletRefundEnabled\` setting.`).requiredOption("--type <value>", `type`).requiredOption("--payload <value>", `payload`).addHelpText("after", `
41799
42094
  Examples:
41800
42095
  hyperline subscriptions create-subscription-update --id <id> --application-schedule <application_schedule> --payment-schedule <payment_schedule> --calculation-method <calculation_method> --type <type> --payload <payload>
41801
42096
  hyperline subscriptions create-subscription-update --id <id> --application-schedule <application_schedule> --payment-schedule <payment_schedule> --calculation-method <calculation_method> --type <type> --payload <payload> --apply-at <apply_at> --charge-at <charge_at>
@@ -41818,6 +42113,10 @@ Examples:
41818
42113
  args.charge_at = opts.chargeAt;
41819
42114
  if (opts.calculationMethod !== void 0)
41820
42115
  args.calculation_method = opts.calculationMethod;
42116
+ if (opts.precision !== void 0)
42117
+ args.precision = opts.precision;
42118
+ if (opts.refundMethod !== void 0)
42119
+ args.refund_method = opts.refundMethod;
41821
42120
  if (opts.type !== void 0)
41822
42121
  args.type = opts.type;
41823
42122
  if (opts.payload !== void 0)
@@ -41829,7 +42128,7 @@ Examples:
41829
42128
  queryParamKeys: []
41830
42129
  });
41831
42130
  });
41832
- resource.command("create-subscription-updates").description(`Apply multiple updates at once to an existing subscription in a single atomic operation.`).requiredOption("--id <value>", `id parameter`).requiredOption("--application-schedule <value>", `application_schedule`).option("--apply-at <value>", `The date when the update should be applied. Required when application_schedule is 'scheduled'.`).requiredOption("--payment-schedule <value>", `payment_schedule`).option("--charge-at <value>", `The date when the resulting subscription update should be charged. Required when payment_schedule is 'custom'. Must be in the future.`).requiredOption("--calculation-method <value>", `calculation_method`).requiredOption("--updates <value>", `updates`).addHelpText("after", `
42131
+ resource.command("create-subscription-updates").description(`Apply multiple updates at once to an existing subscription in a single atomic operation.`).requiredOption("--id <value>", `id parameter`).requiredOption("--application-schedule <value>", `application_schedule`).option("--apply-at <value>", `The date when the update should be applied. Required when application_schedule is 'scheduled'.`).requiredOption("--payment-schedule <value>", `payment_schedule`).option("--charge-at <value>", `The date when the resulting subscription update should be charged. Required when payment_schedule is 'custom'. Must be in the future.`).requiredOption("--calculation-method <value>", `calculation_method`).option("--precision <value>", `Granularity used to prorate the update amount. Defaults to 'calendar_days' when omitted, prorating on whole calendar days; 'milliseconds' prorates on the exact elapsed time, charging the precise partial period.`).option("--refund-method <value>", `Override the refund destination when the update generates a refund credit note (e.g. seat reduction). When omitted, falls back to the invoicing entity's \`creditNoteWalletRefundEnabled\` setting.`).requiredOption("--updates <value>", `updates`).addHelpText("after", `
41833
42132
  Examples:
41834
42133
  hyperline subscriptions create-subscription-updates --id <id> --application-schedule <application_schedule> --payment-schedule <payment_schedule> --calculation-method <calculation_method> --updates <updates>
41835
42134
  hyperline subscriptions create-subscription-updates --id <id> --application-schedule <application_schedule> --payment-schedule <payment_schedule> --calculation-method <calculation_method> --updates <updates> --apply-at <apply_at> --charge-at <charge_at>
@@ -41852,6 +42151,10 @@ Examples:
41852
42151
  args.charge_at = opts.chargeAt;
41853
42152
  if (opts.calculationMethod !== void 0)
41854
42153
  args.calculation_method = opts.calculationMethod;
42154
+ if (opts.precision !== void 0)
42155
+ args.precision = opts.precision;
42156
+ if (opts.refundMethod !== void 0)
42157
+ args.refund_method = opts.refundMethod;
41855
42158
  if (opts.updates !== void 0)
41856
42159
  args.updates = opts.updates;
41857
42160
  await ctx.execute({
@@ -41861,7 +42164,7 @@ Examples:
41861
42164
  queryParamKeys: []
41862
42165
  });
41863
42166
  });
41864
- resource.command("cancel").description(`Cancel a subscription. Supports immediate or end-of-period cancellation. Optionally specify a cancellation reason.`).requiredOption("--id <value>", `id parameter`).option("--cancel-at <value>", `Subscription cancel date. UTC date time string in the [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format.`).option("--reason <value>", `Reason for the cancellation.`).option("--pro-rata", `Indicates if the cancel should refund the customer using a pro rata strategy.`).addHelpText("after", `
42167
+ resource.command("cancel").description(`Cancel a subscription. Supports immediate or end-of-period cancellation. Optionally specify a cancellation reason.`).requiredOption("--id <value>", `id parameter`).option("--cancel-at <value>", `Subscription cancel date. UTC date time string in the [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format.`).option("--reason <value>", `Reason for the cancellation.`).option("--pro-rata", `Indicates if the cancel should refund the customer using a pro rata strategy.`).option("--refund-method <value>", `Override the refund destination for the resulting credit note. When omitted, falls back to the invoicing entity's \`creditNoteWalletRefundEnabled\` setting.`).addHelpText("after", `
41865
42168
  Examples:
41866
42169
  hyperline subscriptions cancel --id <id>
41867
42170
  hyperline subscriptions cancel --id <id> --cancel-at <cancel_at> --reason <reason>
@@ -41878,6 +42181,8 @@ Examples:
41878
42181
  args.cancel_at = opts.cancelAt;
41879
42182
  if (opts.reason !== void 0)
41880
42183
  args.reason = opts.reason;
42184
+ if (opts.refundMethod !== void 0)
42185
+ args.refund_method = opts.refundMethod;
41881
42186
  if (opts.proRata !== void 0)
41882
42187
  args.pro_rata = true;
41883
42188
  await ctx.execute({
@@ -41987,7 +42292,7 @@ Examples:
41987
42292
  queryParamKeys: []
41988
42293
  });
41989
42294
  });
41990
- resource.command("simulate-subscription-updates").description(`Preview the effect of updates on a subscription without applying them. Returns simulated invoice and billing impact.`).requiredOption("--id <value>", `id parameter`).requiredOption("--application-schedule <value>", `application_schedule`).option("--apply-at <value>", `The date when the update should be applied. Required when application_schedule is 'scheduled'.`).requiredOption("--payment-schedule <value>", `payment_schedule`).option("--charge-at <value>", `The date when the resulting subscription update should be charged. Required when payment_schedule is 'custom'. Must be in the future.`).requiredOption("--calculation-method <value>", `calculation_method`).requiredOption("--updates <value>", `updates`).addHelpText("after", `
42295
+ resource.command("simulate-subscription-updates").description(`Preview the effect of updates on a subscription without applying them. Returns simulated invoice and billing impact.`).requiredOption("--id <value>", `id parameter`).requiredOption("--application-schedule <value>", `application_schedule`).option("--apply-at <value>", `The date when the update should be applied. Required when application_schedule is 'scheduled'.`).requiredOption("--payment-schedule <value>", `payment_schedule`).option("--charge-at <value>", `The date when the resulting subscription update should be charged. Required when payment_schedule is 'custom'. Must be in the future.`).requiredOption("--calculation-method <value>", `calculation_method`).option("--precision <value>", `Granularity used to prorate the update amount. Defaults to 'calendar_days' when omitted, prorating on whole calendar days; 'milliseconds' prorates on the exact elapsed time, charging the precise partial period.`).option("--refund-method <value>", `Override the refund destination when the update generates a refund credit note (e.g. seat reduction). When omitted, falls back to the invoicing entity's \`creditNoteWalletRefundEnabled\` setting.`).requiredOption("--updates <value>", `updates`).addHelpText("after", `
41991
42296
  Examples:
41992
42297
  hyperline subscriptions simulate-subscription-updates --id <id> --application-schedule <application_schedule> --payment-schedule <payment_schedule> --calculation-method <calculation_method> --updates <updates>
41993
42298
  hyperline subscriptions simulate-subscription-updates --id <id> --application-schedule <application_schedule> --payment-schedule <payment_schedule> --calculation-method <calculation_method> --updates <updates> --apply-at <apply_at> --charge-at <charge_at>
@@ -42010,6 +42315,10 @@ Examples:
42010
42315
  args.charge_at = opts.chargeAt;
42011
42316
  if (opts.calculationMethod !== void 0)
42012
42317
  args.calculation_method = opts.calculationMethod;
42318
+ if (opts.precision !== void 0)
42319
+ args.precision = opts.precision;
42320
+ if (opts.refundMethod !== void 0)
42321
+ args.refund_method = opts.refundMethod;
42013
42322
  if (opts.updates !== void 0)
42014
42323
  args.updates = opts.updates;
42015
42324
  await ctx.execute({
@@ -42035,7 +42344,7 @@ Strategy used to cancel the subscription. If not specified \`do_nothing\` is use
42035
42344
  - \`refund_custom\`: Will refund to the customer a custom amount.
42036
42345
  - \`end_of_period\`: Will cancel the subscription at the end date of the current billing period.
42037
42346
  - \`do_nothing\`: Will only cease the subscription without any additional actions.
42038
- `).option("--cancellation-amount <number>", `Custom amount used when cancelling the subscription. Only applies to the \`charge_custom\` or the \`refund_custom\` cancellation strategy.`).option("--properties <value>", `Key/value pairs to store any metadata useful in your context.`).option("--custom-properties <value>", `A list of key value with the slug of the custom property as the key and the custom property value as value.`).option("--tax-only <value>", `Only tax will be charged on this subscription.`).option("--generate-draft-invoices <value>", `Generate draft invoices for the subscription. Each invoice will need to be reviewed and validated manually before being sent`).option("--generate-document <value>", `Generate non-legal documents instead of invoices.`).option("--document-name <value>", `If \`generate_document\` is turned on, allows you to give a name to your document.`).option("--add-tax-to-document <value>", `If \`generate_document\` is turned on, will add taxes to document.`).option("--do-not-charge-subscription <value>", `Subscription will be invoiced but not charged (invoices/documents will be settled directly).`).option("--invoice-custom-note <value>", `Default custom note added to invoices generated by the subscription.`).option("--invoice-schedule <value>", `
42347
+ `).option("--cancellation-amount <number>", `Custom amount used when cancelling the subscription. Only applies to the \`charge_custom\` or the \`refund_custom\` cancellation strategy.`).option("--cancellation-refund-method <value>", `Override the refund destination for credit notes generated by \`refund_prorata\` / \`refund_custom\` cancellation strategies. When omitted, falls back to the invoicing entity's \`creditNoteWalletRefundEnabled\` setting.`).option("--properties <value>", `Key/value pairs to store any metadata useful in your context.`).option("--custom-properties <value>", `A list of key value with the slug of the custom property as the key and the custom property value as value.`).option("--tax-only <value>", `Only tax will be charged on this subscription.`).option("--generate-draft-invoices <value>", `Generate draft invoices for the subscription. Each invoice will need to be reviewed and validated manually before being sent`).option("--generate-document <value>", `Generate non-legal documents instead of invoices.`).option("--document-name <value>", `If \`generate_document\` is turned on, allows you to give a name to your document.`).option("--add-tax-to-document <value>", `If \`generate_document\` is turned on, will add taxes to document.`).option("--do-not-charge-subscription <value>", `Subscription will be invoiced but not charged (invoices/documents will be settled directly).`).option("--invoice-custom-note <value>", `Default custom note added to invoices generated by the subscription.`).option("--invoice-schedule <value>", `
42039
42348
  Defines when invoices are generated relative to the billing period.
42040
42349
 
42041
42350
  - \`period_start\`: Invoices are generated at the start of the billing period.
@@ -42090,6 +42399,8 @@ Examples:
42090
42399
  args.cancel_at = opts.cancelAt;
42091
42400
  if (opts.cancellationStrategy !== void 0)
42092
42401
  args.cancellation_strategy = opts.cancellationStrategy;
42402
+ if (opts.cancellationRefundMethod !== void 0)
42403
+ args.cancellation_refund_method = opts.cancellationRefundMethod;
42093
42404
  if (opts.properties !== void 0)
42094
42405
  args.properties = opts.properties;
42095
42406
  if (opts.customProperties !== void 0)
@@ -42372,7 +42683,7 @@ Examples:
42372
42683
  queryParamKeys: []
42373
42684
  });
42374
42685
  });
42375
- resource.command("update").description(`Comprehensive subscription update: modify fields, manage phases (add/update/delete pending phases), update products within phases, and manage coupons. Payload mirrors GET response structure.`).requiredOption("--id <value>", `id parameter`).option("--name <value>", `Subscription custom name.`).option("--purchase-order <value>", `Reference to the purchase order.`).option("--minimum-invoice-fee <number>", `Minimum fee applied to each invoice outside of one time payments.`).option("--crm-opportunity-id <value>", `ID of the related opportunity/deal in the connected CRM.`).option("--tax-only <value>", `Only tax will be charged on this subscription.`).option("--generate-draft-invoices <value>", `Generate draft invoices for the subscription. Each invoice will need to be reviewed and validated manually before being sent`).option("--generate-document <value>", `Generate non-legal documents instead of invoices.`).option("--document-name <value>", `If \`generate_document\` is turned on, allows you to give a name to your document.`).option("--add-tax-to-document <value>", `If \`generate_document\` is turned on, will add taxes to document.`).option("--do-not-charge-subscription <value>", `Subscription will be invoiced but not charged (invoices/documents will be settled directly).`).option("--invoice-custom-note <value>", `Default custom note added to invoices generated by the subscription.`).option("--invoice-schedule <value>", `
42686
+ resource.command("update").description(`Comprehensive subscription update: modify fields, manage phases (add/update/delete pending phases), update products within phases, and manage coupons. Draft quote subscription configuration must be updated through PATCH /v1/quotes/{id}.`).requiredOption("--id <value>", `id parameter`).option("--name <value>", `Subscription custom name.`).option("--purchase-order <value>", `Reference to the purchase order.`).option("--minimum-invoice-fee <number>", `Minimum fee applied to each invoice outside of one time payments.`).option("--crm-opportunity-id <value>", `ID of the related opportunity/deal in the connected CRM.`).option("--tax-only <value>", `Only tax will be charged on this subscription.`).option("--generate-draft-invoices <value>", `Generate draft invoices for the subscription. Each invoice will need to be reviewed and validated manually before being sent`).option("--generate-document <value>", `Generate non-legal documents instead of invoices.`).option("--document-name <value>", `If \`generate_document\` is turned on, allows you to give a name to your document.`).option("--add-tax-to-document <value>", `If \`generate_document\` is turned on, will add taxes to document.`).option("--do-not-charge-subscription <value>", `Subscription will be invoiced but not charged (invoices/documents will be settled directly).`).option("--invoice-custom-note <value>", `Default custom note added to invoices generated by the subscription.`).option("--invoice-schedule <value>", `
42376
42687
  Defines when invoices are generated relative to the billing period.
42377
42688
 
42378
42689
  - \`period_start\`: Invoices are generated at the start of the billing period.
@@ -42732,7 +43043,7 @@ Examples:
42732
43043
  ]
42733
43044
  });
42734
43045
  });
42735
- resource.command("create-subscription-transition").description(`Create a transition from one subscription to another, configured from a subscription, plan, or template. Can be applied immediately or scheduled.`).requiredOption("--source-subscription-id <value>", `The ID of the subscription to transition from`).option("--name <value>", `An optional name for the transition`).option("--calculation-method <value>", `The calculation method to use for the transition. 'do_not_charge' will not generate any transition invoice. 'pro_rata' will generate a prorated invoice for the remaining period.`).option("--billing-cycle-transition-method <value>", `The billing cycle transition method to use. 'keep_current_billing_cycle' will keep the current billing cycle dates if possible. 'align_to_new_billing_cycle' will align the billing cycle to the transition date.`).requiredOption("--application-schedule <value>", `Whether the transition should be applied 'immediately' or 'scheduled' for a specific date. Past dates within the current billing period are supported and will be applied immediately.`).option("--transition-date <value>", `The date at which the transition should occur. Only applicable if the application schedule is 'scheduled'. Can be a past date within the current billing period. UTC date time string in the [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format.`).requiredOption("--target-subscription <value>", `The configuration of the subscription to transition to`).addHelpText("after", `
43046
+ resource.command("create-subscription-transition").description(`Create a transition from one subscription to another, configured from a subscription, plan, or template. Can be applied immediately or scheduled.`).requiredOption("--source-subscription-id <value>", `The ID of the subscription to transition from`).option("--name <value>", `An optional name for the transition`).option("--calculation-method <value>", `The calculation method to use for the transition. 'do_not_charge' will not generate any transition invoice. 'pro_rata' will generate a prorated invoice for the remaining period. 'refund_and_reinvoice' (only available with application_schedule 'last_renewal') issues a credit note for what was invoiced for the current period and a separate invoice for the new configuration.`).option("--billing-cycle-transition-method <value>", `The billing cycle transition method to use. 'keep_current_billing_cycle' will keep the current billing cycle dates if possible. 'align_to_new_billing_cycle' will align the billing cycle to the transition date.`).requiredOption("--application-schedule <value>", `When the transition should be applied: 'immediately', 'scheduled' for a specific date, or 'last_renewal' to apply it retroactively to the start of the current billing period (refunding what was already invoiced for that period and re-charging the new configuration). Past dates within the current billing period are supported and will be applied immediately.`).option("--transition-date <value>", `The date at which the transition should occur. Only applicable if the application schedule is 'scheduled'. Can be a past date within the current billing period. UTC date time string in the [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format.`).requiredOption("--target-subscription <value>", `The configuration of the subscription to transition to`).addHelpText("after", `
42736
43047
  Examples:
42737
43048
  hyperline subscriptions-transitions create-subscription-transition --source-subscription-id <source_subscription_id> --application-schedule <application_schedule> --target-subscription <target_subscription>
42738
43049
  hyperline subscriptions-transitions create-subscription-transition --source-subscription-id <source_subscription_id> --application-schedule <application_schedule> --target-subscription <target_subscription> --name <name> --calculation-method <calculation_method>
@@ -42946,6 +43257,30 @@ Examples:
42946
43257
  });
42947
43258
  }
42948
43259
 
43260
+ // build/commands/generated/transactions.js
43261
+ function registerTransactionsCommands(parent) {
43262
+ const resource = parent.command("transactions").description("Manage transactions");
43263
+ resource.command("refund").description(`Refund a settled banking transaction for its full amount. The related invoice will switch back to to pay status. Use the create credit note endpoint if you want to cancel (and optionally refund) the initial invoice.`).requiredOption("--id <value>", `id parameter`).addHelpText("after", `
43264
+ Examples:
43265
+ hyperline transactions refund --id <id>
43266
+ hyperline transactions refund --id <id> --output json`).action(async (opts) => {
43267
+ const ctx = resource.parent?.opts()._ctx;
43268
+ if (!ctx) {
43269
+ process.stderr.write("Error: Not authenticated\n");
43270
+ process.exit(1);
43271
+ }
43272
+ const args = {};
43273
+ if (opts.id !== void 0)
43274
+ args.id = opts.id;
43275
+ await ctx.execute({
43276
+ method: "POST",
43277
+ path: "/v1/transactions/{id}/refund",
43278
+ args,
43279
+ queryParamKeys: []
43280
+ });
43281
+ });
43282
+ }
43283
+
42949
43284
  // build/commands/generated/wallets.js
42950
43285
  function registerWalletsCommands(parent) {
42951
43286
  const resource = parent.command("wallets").description("Manage wallets");
@@ -43106,10 +43441,10 @@ Examples:
43106
43441
  queryParamKeys: []
43107
43442
  });
43108
43443
  });
43109
- resource.command("load").description(`Add credits to a wallet by charging the customer's payment method. The customer must have an active payment method.`).requiredOption("--id <value>", `id parameter`).option("--amount <number>", `Amount to be loaded onto the wallet. A corresponding invoice to pay will be generated. Expressed in currency's smallest unit.`).option("--amount-free <number>", `Amount free/offered to be loaded onto the wallet. No invoice is generated. Expressed in currency's smallest unit.`).option("--document-status <value>", `Indicates the status of the document (credit note in case of free top-up or invoice)`).addHelpText("after", `
43444
+ resource.command("load").description(`Add paid credits by charging the customer's payment method, or add free credits by issuing a credit note.`).requiredOption("--id <value>", `id parameter`).option("--type <value>", `Wallet load type. Use \`paid\` to collect payment from the customer's payment method, or \`free\` to grant credits without collecting payment.`).option("--amount <number>", `Amount to be loaded onto the wallet as free credits. A corresponding credit note will be generated and no payment is collected. Expressed in currency's smallest unit.`).option("--comment <value>", `Internal comment stored on the wallet transaction for context.`).option("--document-status <value>", `Indicates the status of the generated credit note for free top-ups.`).option("--bank-account-id <value>", `Bank account ID to use when recording a paid wallet load by bank transfer.`).option("--reference <value>", `Reference stored on the generated payment document for a paid wallet load.`).addHelpText("after", `
43110
43445
  Examples:
43111
43446
  hyperline wallets load --id <id>
43112
- hyperline wallets load --id <id> --amount <amount> --amount-free <amount_free>
43447
+ hyperline wallets load --id <id> --type <type> --amount <amount>
43113
43448
  hyperline wallets load --id <id> --output json`).action(async (opts) => {
43114
43449
  const ctx = resource.parent?.opts()._ctx;
43115
43450
  if (!ctx) {
@@ -43119,12 +43454,18 @@ Examples:
43119
43454
  const args = {};
43120
43455
  if (opts.id !== void 0)
43121
43456
  args.id = opts.id;
43457
+ if (opts.type !== void 0)
43458
+ args.type = opts.type;
43459
+ if (opts.comment !== void 0)
43460
+ args.comment = opts.comment;
43122
43461
  if (opts.documentStatus !== void 0)
43123
43462
  args.document_status = opts.documentStatus;
43463
+ if (opts.bankAccountId !== void 0)
43464
+ args.bank_account_id = opts.bankAccountId;
43465
+ if (opts.reference !== void 0)
43466
+ args.reference = opts.reference;
43124
43467
  if (opts.amount !== void 0)
43125
43468
  args.amount = Number(opts.amount);
43126
- if (opts.amountFree !== void 0)
43127
- args.amount_free = Number(opts.amountFree);
43128
43469
  await ctx.execute({
43129
43470
  method: "POST",
43130
43471
  path: "/v1/wallets/{id}/load",
@@ -43353,11 +43694,13 @@ function registerAllCommands(program2) {
43353
43694
  registerProductsCommands(program2);
43354
43695
  registerPrice_ConfigurationsCommands(program2);
43355
43696
  registerQuotesCommands(program2);
43697
+ registerQuotes_TemplatesCommands(program2);
43356
43698
  registerSubscriptions_TemplatesCommands(program2);
43357
43699
  registerSubscriptionsCommands(program2);
43358
43700
  registerSubscriptions_TransitionsCommands(program2);
43359
43701
  registerSubscriptions_PhasesCommands(program2);
43360
43702
  registerTaxesCommands(program2);
43703
+ registerTransactionsCommands(program2);
43361
43704
  registerWalletsCommands(program2);
43362
43705
  registerWebhooksCommands(program2);
43363
43706
  }
@@ -57148,6 +57491,7 @@ var BooleanSchema = external_exports.boolean().or(external_exports.enum(["true",
57148
57491
  });
57149
57492
  var StringSchemaForMultipartForm = external_exports.string().transform((value) => value === "" ? null : value);
57150
57493
  var StringArraySchemaForMultipartForm = external_exports.string().array().or(external_exports.string().length(0)).transform((value) => typeof value === "string" ? [] : value);
57494
+ var CommaSeparatedArraySchema = external_exports.string().optional().transform((raw) => raw ? raw.split(",").filter(Boolean) : void 0);
57151
57495
  var urlRegex = /^(?:(?:https?):\/\/)?(?:www\.)?(?:[\w-]+\.)+[a-z]{2,7}(?:\/\S*)?$/i;
57152
57496
  var ZodFlexibleUrl = external_exports.string({ message: "Invalid URL" }).regex(urlRegex).transform((url2) => {
57153
57497
  if (!url2)
@@ -61460,6 +61804,7 @@ function getConfig(schema, testValues) {
61460
61804
  var config3 = getConfig({
61461
61805
  // config
61462
61806
  APP_VERSION: types.string().optional(),
61807
+ DD_SERVICE: types.string().optional(),
61463
61808
  LOGGER_CONSOLE_ENABLED: types.boolean().optional(),
61464
61809
  LOGGER_STDOUT_ENABLED: types.boolean().optional(),
61465
61810
  NODE_ENV: types.enum(["local", "test", "staging", "sandbox", "production"]),
@@ -61469,6 +61814,7 @@ var config3 = getConfig({
61469
61814
  // secrets
61470
61815
  }, {
61471
61816
  APP_VERSION: void 0,
61817
+ DD_SERVICE: void 0,
61472
61818
  LOGGER_CONSOLE_ENABLED: false,
61473
61819
  LOGGER_STDOUT_ENABLED: false,
61474
61820
  EVENT_LOOP_MONITORING_ENABLED: false,
@@ -61484,6 +61830,7 @@ import * as winston from "winston";
61484
61830
 
61485
61831
  // ../hyperline-monitoring/build/logger/formatting/format.js
61486
61832
  import prune from "json-prune";
61833
+ var REDACTED_HEADER_KEY_PATTERN = /authorization|authenticate|cookie|secret|token|credential|signature|jwt|api[_-]?key|access[_-]?token|refresh[_-]?token|private[_-]?key/i;
61487
61834
  function jsonFormat(info) {
61488
61835
  const prunedInfo = JSON.parse(prune(info));
61489
61836
  for (const [key, value] of Object.entries(prunedInfo)) {
@@ -61566,17 +61913,26 @@ function formatAxiosError(error48) {
61566
61913
  url: request?.url,
61567
61914
  baseURL: request?.baseURL,
61568
61915
  params: request?.params,
61569
- headers: request?.headers,
61916
+ headers: redactHeaders({ headers: request?.headers }),
61570
61917
  "axios-retry": request?.["axios-retry"]
61571
61918
  },
61572
61919
  response: {
61573
61920
  status: response?.status,
61574
61921
  statusText: response?.statusText,
61575
- headers: response?.headers,
61922
+ headers: redactHeaders({ headers: response?.headers }),
61576
61923
  data: response?.data
61577
61924
  }
61578
61925
  };
61579
61926
  }
61927
+ function redactHeaders({ headers }) {
61928
+ if (!isRecord(headers)) {
61929
+ return headers;
61930
+ }
61931
+ return Object.fromEntries(Object.entries(headers).map(([headerKey, headerValue]) => [
61932
+ headerKey,
61933
+ REDACTED_HEADER_KEY_PATTERN.test(headerKey) ? "<redacted>" : headerValue
61934
+ ]));
61935
+ }
61580
61936
  function isRecord(value) {
61581
61937
  return typeof value === "object" && value !== null && !Array.isArray(value);
61582
61938
  }
@@ -61600,13 +61956,16 @@ function logHttpRequest(logger2, request, extra) {
61600
61956
  });
61601
61957
  }
61602
61958
  function logHttpResponse(logger2, response, responseTime, extra) {
61603
- const { request, statusCode, responseBody } = response;
61959
+ const { request, statusCode, responseBody, responseHeaders } = response;
61604
61960
  const { message, metadata } = transform2(request);
61605
61961
  const readableResponseTime = responseTime ? getReadableTime(responseTime) : void 0;
61606
61962
  const responseMetadata = {
61607
61963
  statusCode,
61608
61964
  responseTime,
61609
- responseBody
61965
+ responseBody,
61966
+ // Redacted so secrets (authorization/cookie/token/…) never reach the logs
61967
+ // while diagnostic headers (e.g. rate-limit headers on a 429) stay visible.
61968
+ responseHeaders: responseHeaders === void 0 ? void 0 : redactHeaders({ headers: responseHeaders })
61610
61969
  };
61611
61970
  logger2.info(`HTTP RES - ${message} ${statusCode} ${readableResponseTime || ""} ${extra?.postfix || ""}`, {
61612
61971
  ...metadata,
@@ -61747,13 +62106,16 @@ var loggerFactory = buildLoggerFactory({
61747
62106
  },
61748
62107
  context: {
61749
62108
  env: config3.NODE_ENV,
61750
- service: "api",
62109
+ service: config3.DD_SERVICE ?? "api",
61751
62110
  version: config3.APP_VERSION
61752
62111
  }
61753
62112
  });
61754
62113
  var createLogger2 = loggerFactory.createLogger;
61755
62114
  var logger = loggerFactory.createLogger({ serviceName: "default" });
61756
62115
 
62116
+ // ../hyperline-monitoring/build/tracing/tracing.js
62117
+ import tracer from "dd-trace";
62118
+
61757
62119
  // ../hyperline-lib/build/utils/config/usStates.js
61758
62120
  var usStates = [
61759
62121
  "AA",
@@ -61895,6 +62257,20 @@ var PublicPaginationParams = {
61895
62257
  skip: zod_default.coerce.number().nonnegative().optional().default(0)
61896
62258
  };
61897
62259
  var PublicPaginationSchema = zod_default.object(PublicPaginationParams);
62260
+ var PublicCursorPaginationParams = {
62261
+ limit: zod_default.coerce.number().positive().max(100).optional().default(50).openapi({
62262
+ description: "Maximum number of items to return (1-100).",
62263
+ example: 50
62264
+ }),
62265
+ cursor: zod_default.string().optional().openapi({
62266
+ description: "Opaque cursor returned in the previous response's `next_cursor`. Omit to fetch the first page."
62267
+ }),
62268
+ include_total: BooleanSchema.optional().default(false).openapi({
62269
+ description: "Set to `true` to include `total` in the response.",
62270
+ example: false
62271
+ })
62272
+ };
62273
+ var PublicCursorPaginationSchema = zod_default.object(PublicCursorPaginationParams);
61898
62274
 
61899
62275
  // ../hyperline-lib/build/http/dto/state.js
61900
62276
  var StateSchema = external_exports.enum(usStates).openapi({
@@ -61924,10 +62300,12 @@ var languages = [
61924
62300
  var de = {
61925
62301
  "accounting.invoicePosted.entryDescription": "Buchungseintrag f\xFCr Rechnung {{invoiceId}}",
61926
62302
  "accounting.transactionSettled.entryDescription": "Zahlungsabwicklung f\xFCr Rechnung {{invoiceId}}",
62303
+ "accounting.transactionRefunded.entryDescription": "R\xFCckerstattung f\xFCr Rechnung {{invoiceId}}",
61927
62304
  "accounting.creditNotePosted.entryDescription": "Gutschrift {{creditNoteId}} f\xFCr Rechnung {{invoiceId}}",
61928
62305
  "accounting.revrec.creditLineDescription": "Umsatz realisieren \u2013 Zeitplan {{scheduleId}}, Zeitraum {{periodDate}}",
61929
62306
  "accounting.revrec.debitLineDescription": "Abgrenzungsposten reduzieren \u2013 Zeitplan {{scheduleId}}, Zeitraum {{periodDate}}",
61930
62307
  "accounting.revrec.discountCreditLineDescription": "Erl\xF6sminderung (Rabatt) erfassen \u2013 Zeitplan {{scheduleId}}, Zeitraum {{periodDate}}",
62308
+ "accounting.revrec.closedPeriodFallbackNote": " (in die n\xE4chste offene Periode gebucht \u2013 Zielperiode geschlossen; urspr\xFCngliches Datum {{originalDate}})",
61931
62309
  "accounting.revrec.discountDebitLineDescription": "Abgegrenzten Rabatt reduzieren \u2013 Zeitplan {{scheduleId}}, Zeitraum {{periodDate}}",
61932
62310
  "accounting.revrec.entryDescription": "Umsatzrealisierung f\xFCr Zeitplan {{scheduleId}}, Zeitraum {{periodStart}} - {{periodEnd}}",
61933
62311
  "creditNotes.refundChargeName": "R\xFCckerstattung f\xFCr die Rechnung",
@@ -61940,7 +62318,9 @@ var de = {
61940
62318
  "invoices.outstandingProduct.descriptionPeriod": "Unbezahlter Betrag der Rechnung{{invoiceNumber}} vom {{periodStart}} bis {{periodEnd}}",
61941
62319
  "invoices.outstandingProduct.name": "Offener Saldo",
61942
62320
  "invoices.prorata.paymentForItem": "Anteilig berechneter Betrag f\xFCr",
62321
+ "invoices.prorata.paymentForItemFullPeriod": "Zahlung f\xFCr",
61943
62322
  "invoices.prorata.refundForItem": "Anteilig erstatteter Betrag f\xFCr",
62323
+ "invoices.prorata.refundForItemFullPeriod": "Erstattung f\xFCr",
61944
62324
  "subscriptions.closingChargeName": "Abschlussgeb\xFChr f\xFCr das Abonnement",
61945
62325
  "subscriptions.correction": "Vorperiodische Anpassung",
61946
62326
  "subscriptions.updates.addCoupon": "Gutschein hinzuf\xFCgen {{couponName}}",
@@ -61969,7 +62349,9 @@ var en = {
61969
62349
  "invoices.outstandingProduct.descriptionPeriod": "Unpaid amount from the invoice{{invoiceNumber}} from {{periodStart}} to {{periodEnd}}",
61970
62350
  "invoices.outstandingProduct.name": "Outstanding balance",
61971
62351
  "invoices.prorata.paymentForItem": "Prorated payment for",
62352
+ "invoices.prorata.paymentForItemFullPeriod": "Payment for",
61972
62353
  "invoices.prorata.refundForItem": "Prorated refund for",
62354
+ "invoices.prorata.refundForItemFullPeriod": "Refund for",
61973
62355
  "subscriptions.closingChargeName": "Closing fee for subscription",
61974
62356
  "subscriptions.correction": "Adjustment previous period",
61975
62357
  "subscriptions.updates.addCoupon": "Add coupon {{couponName}}",
@@ -61989,12 +62371,14 @@ var en = {
61989
62371
  "subscriptions.updates.updateCount.description.full.not_committed.not_invoiced": "Amount of {{amount}} not invoiced for the full period",
61990
62372
  "accounting.invoicePosted.entryDescription": "Posting entry for Invoice {{invoiceId}} issued",
61991
62373
  "accounting.transactionSettled.entryDescription": "Payment settlement for Invoice {{invoiceId}}",
62374
+ "accounting.transactionRefunded.entryDescription": "Refund for Invoice {{invoiceId}}",
61992
62375
  "accounting.creditNotePosted.entryDescription": "Credit note {{creditNoteId}} for Invoice {{invoiceId}}",
61993
62376
  "accounting.revrec.entryDescription": "Revenue recognition for schedule {{scheduleId}}, period {{periodStart}} - {{periodEnd}}",
61994
62377
  "accounting.revrec.debitLineDescription": "Decrease deferred revenue \u2013 schedule {{scheduleId}}, period {{periodDate}}",
61995
62378
  "accounting.revrec.creditLineDescription": "Recognize revenue \u2013 schedule {{scheduleId}}, period {{periodDate}}",
61996
62379
  "accounting.revrec.discountDebitLineDescription": "Decrease deferred discount \u2013 schedule {{scheduleId}}, period {{periodDate}}",
61997
62380
  "accounting.revrec.discountCreditLineDescription": "Recognize contra-revenue (discount) \u2013 schedule {{scheduleId}}, period {{periodDate}}",
62381
+ "accounting.revrec.closedPeriodFallbackNote": " (posted to next open period \u2014 target accounting period closed; original date {{originalDate}})",
61998
62382
  "einvoicing.paymentProcessed": "Payment processed",
61999
62383
  "einvoicing.paymentReceived": "Payment received",
62000
62384
  "einvoicing.paymentFromWallet": "Payment from wallet"
@@ -62004,10 +62388,12 @@ var en = {
62004
62388
  var es = {
62005
62389
  "accounting.invoicePosted.entryDescription": "Asiento contable para la factura {{invoiceId}}",
62006
62390
  "accounting.transactionSettled.entryDescription": "Liquidaci\xF3n de pago para la factura {{invoiceId}}",
62391
+ "accounting.transactionRefunded.entryDescription": "Reembolso de la factura {{invoiceId}}",
62007
62392
  "accounting.creditNotePosted.entryDescription": "Nota de cr\xE9dito {{creditNoteId}} para la factura {{invoiceId}}",
62008
62393
  "accounting.revrec.creditLineDescription": "Reconocer ingresos \u2013 cronograma {{scheduleId}}, per\xEDodo {{periodDate}}",
62009
62394
  "accounting.revrec.debitLineDescription": "Disminuci\xF3n de ingresos diferidos \u2013 cronograma {{scheduleId}}, per\xEDodo {{periodDate}}",
62010
62395
  "accounting.revrec.discountCreditLineDescription": "Reconocer contra-ingresos (descuento) \u2013 cronograma {{scheduleId}}, per\xEDodo {{periodDate}}",
62396
+ "accounting.revrec.closedPeriodFallbackNote": " (registrado en el pr\xF3ximo per\xEDodo abierto \u2014 per\xEDodo contable de destino cerrado; fecha original {{originalDate}})",
62011
62397
  "accounting.revrec.discountDebitLineDescription": "Disminuci\xF3n de descuento diferido \u2013 cronograma {{scheduleId}}, per\xEDodo {{periodDate}}",
62012
62398
  "accounting.revrec.entryDescription": "Reconocimiento de ingresos para el cronograma {{scheduleId}}, per\xEDodo {{periodStart}} - {{periodEnd}}",
62013
62399
  "creditNotes.refundChargeName": "Reembolso por factura",
@@ -62020,7 +62406,9 @@ var es = {
62020
62406
  "invoices.outstandingProduct.descriptionPeriod": "Monto pendiente de la factura{{invoiceNumber}} del {{periodStart}} al {{periodEnd}}",
62021
62407
  "invoices.outstandingProduct.name": "Saldo pendiente",
62022
62408
  "invoices.prorata.paymentForItem": "Pago prorrateado por",
62409
+ "invoices.prorata.paymentForItemFullPeriod": "Pago por",
62023
62410
  "invoices.prorata.refundForItem": "Reembolso prorrateado por",
62411
+ "invoices.prorata.refundForItemFullPeriod": "Reembolso por",
62024
62412
  "subscriptions.closingChargeName": "Cargo por cierre de suscripci\xF3n",
62025
62413
  "subscriptions.correction": "Ajuste del periodo anterior",
62026
62414
  "subscriptions.updates.addCoupon": "A\xF1adir cup\xF3n {{couponName}}",
@@ -62045,9 +62433,11 @@ var fr = {
62045
62433
  "accounting.revrec.creditLineDescription": "Reconnaissance du chiffre d'affaires \u2013 \xE9ch\xE9ancier {{scheduleId}}, p\xE9riode {{periodDate}}",
62046
62434
  "accounting.revrec.debitLineDescription": "Diminution des produits constat\xE9s d'avance \u2013 \xE9ch\xE9ancier {{scheduleId}}, p\xE9riode {{periodDate}}",
62047
62435
  "accounting.revrec.discountCreditLineDescription": "Reconnaissance du contre-revenu (remise) \u2013 \xE9ch\xE9ancier {{scheduleId}}, p\xE9riode {{periodDate}}",
62436
+ "accounting.revrec.closedPeriodFallbackNote": " (comptabilis\xE9 sur la prochaine p\xE9riode ouverte \u2014 p\xE9riode comptable cible cl\xF4tur\xE9e ; date d'origine {{originalDate}})",
62048
62437
  "accounting.revrec.discountDebitLineDescription": "Diminution des remises diff\xE9r\xE9es \u2013 \xE9ch\xE9ancier {{scheduleId}}, p\xE9riode {{periodDate}}",
62049
62438
  "accounting.invoicePosted.entryDescription": "\xC9criture de comptabilisation pour la facture {{invoiceId}}",
62050
62439
  "accounting.transactionSettled.entryDescription": "R\xE8glement de la facture {{invoiceId}}",
62440
+ "accounting.transactionRefunded.entryDescription": "Remboursement de la facture {{invoiceId}}",
62051
62441
  "accounting.creditNotePosted.entryDescription": "Avoir {{creditNoteId}} pour la facture {{invoiceId}}",
62052
62442
  "accounting.revrec.entryDescription": "Reconnaissance du chiffre d'affaires pour l'\xE9ch\xE9ancier {{scheduleId}}, p\xE9riode {{periodStart}} - {{periodEnd}}",
62053
62443
  "creditNotes.refundChargeName": "Remboursement pour facture",
@@ -62060,7 +62450,9 @@ var fr = {
62060
62450
  "invoices.outstandingProduct.descriptionPeriod": "Montant impay\xE9 de la facture{{invoiceNumber}} du {{periodStart}} au {{periodEnd}}",
62061
62451
  "invoices.outstandingProduct.name": "Solde impay\xE9",
62062
62452
  "invoices.prorata.paymentForItem": "Paiement au prorata pour",
62453
+ "invoices.prorata.paymentForItemFullPeriod": "Paiement pour",
62063
62454
  "invoices.prorata.refundForItem": "Remboursement au prorata pour",
62455
+ "invoices.prorata.refundForItemFullPeriod": "Remboursement pour",
62064
62456
  "subscriptions.closingChargeName": "Frais de cl\xF4ture pour abonnement",
62065
62457
  "subscriptions.correction": "Ajustement p\xE9riode pr\xE9c\xE9dente",
62066
62458
  "subscriptions.updates.addCoupon": "Ajout du coupon {{couponName}}",
@@ -62084,10 +62476,12 @@ var fr = {
62084
62476
  var it = {
62085
62477
  "accounting.invoicePosted.entryDescription": "Registrazione contabile per la fattura {{invoiceId}}",
62086
62478
  "accounting.transactionSettled.entryDescription": "Regolamento pagamento per la fattura {{invoiceId}}",
62479
+ "accounting.transactionRefunded.entryDescription": "Rimborso per la fattura {{invoiceId}}",
62087
62480
  "accounting.creditNotePosted.entryDescription": "Nota di credito {{creditNoteId}} per la fattura {{invoiceId}}",
62088
62481
  "accounting.revrec.creditLineDescription": "Riconoscere i ricavi \u2013 programma {{scheduleId}}, periodo {{periodDate}}",
62089
62482
  "accounting.revrec.debitLineDescription": "Diminuzione dei ricavi differiti \u2013 programma {{scheduleId}}, periodo {{periodDate}}",
62090
62483
  "accounting.revrec.discountCreditLineDescription": "Riconoscere il contra-ricavo (sconto) \u2013 programma {{scheduleId}}, periodo {{periodDate}}",
62484
+ "accounting.revrec.closedPeriodFallbackNote": " (registrato nel prossimo periodo aperto \u2014 periodo contabile di destinazione chiuso; data originale {{originalDate}})",
62091
62485
  "accounting.revrec.discountDebitLineDescription": "Diminuzione dello sconto differito \u2013 programma {{scheduleId}}, periodo {{periodDate}}",
62092
62486
  "accounting.revrec.entryDescription": "Riconoscimento dei ricavi per il programma {{scheduleId}}, periodo {{periodStart}} - {{periodEnd}}",
62093
62487
  "creditNotes.refundChargeName": "Rimborso per fattura",
@@ -62100,7 +62494,9 @@ var it = {
62100
62494
  "invoices.outstandingProduct.descriptionPeriod": "Importo insoluto della fattura{{invoiceNumber}} dal {{periodStart}} al {{periodEnd}}",
62101
62495
  "invoices.outstandingProduct.name": "Saldo insoluto",
62102
62496
  "invoices.prorata.paymentForItem": "Pagamento proporzionale per",
62497
+ "invoices.prorata.paymentForItemFullPeriod": "Pagamento per",
62103
62498
  "invoices.prorata.refundForItem": "Rimborso proporzionale per",
62499
+ "invoices.prorata.refundForItemFullPeriod": "Rimborso per",
62104
62500
  "subscriptions.closingChargeName": "Costo di chiusura per abbonamento",
62105
62501
  "subscriptions.correction": "Correzione periodo precedente",
62106
62502
  "subscriptions.updates.addCoupon": "Aggiungi coupon {{couponName}}",
@@ -62124,10 +62520,12 @@ var it = {
62124
62520
  var nl = {
62125
62521
  "accounting.invoicePosted.entryDescription": "Boekingsregel voor factuur {{invoiceId}}",
62126
62522
  "accounting.transactionSettled.entryDescription": "Betalingsafwikkeling voor factuur {{invoiceId}}",
62523
+ "accounting.transactionRefunded.entryDescription": "Terugbetaling voor factuur {{invoiceId}}",
62127
62524
  "accounting.creditNotePosted.entryDescription": "Creditnota {{creditNoteId}} voor factuur {{invoiceId}}",
62128
62525
  "accounting.revrec.creditLineDescription": "Omzet erkennen \u2013 schema {{scheduleId}}, periode {{periodDate}}",
62129
62526
  "accounting.revrec.debitLineDescription": "Uitgestelde omzet verlagen \u2013 schema {{scheduleId}}, periode {{periodDate}}",
62130
62527
  "accounting.revrec.discountCreditLineDescription": "Omzetvermindering (korting) erkennen \u2013 schema {{scheduleId}}, periode {{periodDate}}",
62528
+ "accounting.revrec.closedPeriodFallbackNote": " (geboekt in de volgende open periode \u2014 doelboekingsperiode gesloten; oorspronkelijke datum {{originalDate}})",
62131
62529
  "accounting.revrec.discountDebitLineDescription": "Uitgestelde korting verlagen \u2013 schema {{scheduleId}}, periode {{periodDate}}",
62132
62530
  "accounting.revrec.entryDescription": "Omzeterkenning voor schema {{scheduleId}}, periode {{periodStart}} - {{periodEnd}}",
62133
62531
  "creditNotes.refundChargeName": "Terugbetaling voor factuur",
@@ -62140,7 +62538,9 @@ var nl = {
62140
62538
  "invoices.outstandingProduct.descriptionPeriod": "Onbetaald bedrag van de factuur{{invoiceNumber}} van {{periodStart}} tot {{periodEnd}}",
62141
62539
  "invoices.outstandingProduct.name": "Openstaand saldo",
62142
62540
  "invoices.prorata.paymentForItem": "Gedeeltelijke betaling voor",
62541
+ "invoices.prorata.paymentForItemFullPeriod": "Betaling voor",
62143
62542
  "invoices.prorata.refundForItem": "Gedeeltelijke terugbetaling voor",
62543
+ "invoices.prorata.refundForItemFullPeriod": "Terugbetaling voor",
62144
62544
  "subscriptions.closingChargeName": "Afsluitkosten voor abonnement",
62145
62545
  "subscriptions.correction": "Aanpassing vorige periode",
62146
62546
  "subscriptions.updates.addCoupon": "Coupon toevoegen {{couponName}}",
@@ -62164,10 +62564,12 @@ var nl = {
62164
62564
  var pl = {
62165
62565
  "accounting.invoicePosted.entryDescription": "Zapis ksi\u0119gowy dla faktury {{invoiceId}}",
62166
62566
  "accounting.transactionSettled.entryDescription": "Rozliczenie p\u0142atno\u015Bci dla faktury {{invoiceId}}",
62567
+ "accounting.transactionRefunded.entryDescription": "Zwrot za faktur\u0119 {{invoiceId}}",
62167
62568
  "accounting.creditNotePosted.entryDescription": "Nota kredytowa {{creditNoteId}} dla faktury {{invoiceId}}",
62168
62569
  "accounting.revrec.creditLineDescription": "Rozpoznanie przychodu \u2013 harmonogram {{scheduleId}}, okres {{periodDate}}",
62169
62570
  "accounting.revrec.debitLineDescription": "Zmniejszenie przychod\xF3w przysz\u0142ych okres\xF3w \u2013 harmonogram {{scheduleId}}, okres {{periodDate}}",
62170
62571
  "accounting.revrec.discountCreditLineDescription": "Rozpoznanie kontra-przychodu (rabat) \u2013 harmonogram {{scheduleId}}, okres {{periodDate}}",
62572
+ "accounting.revrec.closedPeriodFallbackNote": " (zaksi\u0119gowano w nast\u0119pnym otwartym okresie \u2014 docelowy okres ksi\u0119gowy zamkni\u0119ty; pierwotna data {{originalDate}})",
62171
62573
  "accounting.revrec.discountDebitLineDescription": "Zmniejszenie odroczonego rabatu \u2013 harmonogram {{scheduleId}}, okres {{periodDate}}",
62172
62574
  "accounting.revrec.entryDescription": "Rozpoznanie przychodu dla harmonogramu {{scheduleId}}, okres {{periodStart}} - {{periodEnd}}",
62173
62575
  "creditNotes.refundChargeName": "Zwrot za faktur\u0119",
@@ -62180,7 +62582,9 @@ var pl = {
62180
62582
  "invoices.outstandingProduct.descriptionPeriod": "Nieop\u0142acona kwota z faktury{{invoiceNumber}} od {{periodStart}} do {{periodEnd}}",
62181
62583
  "invoices.outstandingProduct.name": "Niezap\u0142acone saldo",
62182
62584
  "invoices.prorata.paymentForItem": "P\u0142atno\u015B\u0107 proporcjonalna za",
62585
+ "invoices.prorata.paymentForItemFullPeriod": "P\u0142atno\u015B\u0107 za",
62183
62586
  "invoices.prorata.refundForItem": "Zwrot proporcjonalny za",
62587
+ "invoices.prorata.refundForItemFullPeriod": "Zwrot za",
62184
62588
  "subscriptions.closingChargeName": "Op\u0142ata za zamkni\u0119cie subskrypcji",
62185
62589
  "subscriptions.correction": "Korekta poprzedniego okresu",
62186
62590
  "subscriptions.updates.addCoupon": "Dodaj kupon {{couponName}}",
@@ -62204,10 +62608,12 @@ var pl = {
62204
62608
  var pt = {
62205
62609
  "accounting.invoicePosted.entryDescription": "Lan\xE7amento cont\xE1bil para a fatura {{invoiceId}}",
62206
62610
  "accounting.transactionSettled.entryDescription": "Liquida\xE7\xE3o de pagamento para a fatura {{invoiceId}}",
62611
+ "accounting.transactionRefunded.entryDescription": "Reembolso da fatura {{invoiceId}}",
62207
62612
  "accounting.creditNotePosted.entryDescription": "Nota de cr\xE9dito {{creditNoteId}} para a fatura {{invoiceId}}",
62208
62613
  "accounting.revrec.creditLineDescription": "Reconhecer receita \u2013 cronograma {{scheduleId}}, per\xEDodo {{periodDate}}",
62209
62614
  "accounting.revrec.debitLineDescription": "Diminui\xE7\xE3o da receita diferida \u2013 cronograma {{scheduleId}}, per\xEDodo {{periodDate}}",
62210
62615
  "accounting.revrec.discountCreditLineDescription": "Reconhecer contra-receita (desconto) \u2013 cronograma {{scheduleId}}, per\xEDodo {{periodDate}}",
62616
+ "accounting.revrec.closedPeriodFallbackNote": " (lan\xE7ado no pr\xF3ximo per\xEDodo aberto \u2014 per\xEDodo cont\xE1bil de destino fechado; data original {{originalDate}})",
62211
62617
  "accounting.revrec.discountDebitLineDescription": "Diminui\xE7\xE3o do desconto diferido \u2013 cronograma {{scheduleId}}, per\xEDodo {{periodDate}}",
62212
62618
  "accounting.revrec.entryDescription": "Reconhecimento de receita para o cronograma {{scheduleId}}, per\xEDodo {{periodStart}} - {{periodEnd}}",
62213
62619
  "creditNotes.refundChargeName": "Reembolso pela fatura",
@@ -62220,7 +62626,9 @@ var pt = {
62220
62626
  "invoices.outstandingProduct.descriptionPeriod": "Valor em aberto da fatura{{invoiceNumber}} de {{periodStart}} a {{periodEnd}}",
62221
62627
  "invoices.outstandingProduct.name": "Saldo em aberto",
62222
62628
  "invoices.prorata.paymentForItem": "Pagamento proporcional por",
62629
+ "invoices.prorata.paymentForItemFullPeriod": "Pagamento por",
62223
62630
  "invoices.prorata.refundForItem": "Reembolso proporcional por",
62631
+ "invoices.prorata.refundForItemFullPeriod": "Reembolso por",
62224
62632
  "subscriptions.closingChargeName": "Taxa de encerramento da assinatura",
62225
62633
  "subscriptions.correction": "Ajuste do per\xEDodo anterior",
62226
62634
  "subscriptions.updates.addCoupon": "Adicionar cupom {{couponName}}",
@@ -62342,10 +62750,16 @@ function buildHttpClient(dependencies) {
62342
62750
  return response;
62343
62751
  }, (error48) => {
62344
62752
  if (error48.response) {
62345
- const { config: responseConfig, status } = error48.response;
62753
+ const { config: responseConfig, status, headers } = error48.response;
62346
62754
  const timeStart = responseConfig.metadata.timeStart;
62347
62755
  const responseTime = timeStart ? Date.now() - timeStart : void 0;
62348
- logHttpResponse(logger2, { request: toLogRequest(responseConfig), statusCode: status }, responseTime, { metadata: { error: error48.message } });
62756
+ logHttpResponse(logger2, {
62757
+ request: toLogRequest(responseConfig),
62758
+ statusCode: status,
62759
+ // Surfaces upstream response headers on error responses (e.g. the
62760
+ // rate-limit headers on a 429); redacted in logHttpResponse.
62761
+ responseHeaders: headers
62762
+ }, responseTime, { metadata: { error: error48.message } });
62349
62763
  }
62350
62764
  return Promise.reject(error48);
62351
62765
  });
@@ -62438,6 +62852,9 @@ import { StreamableHTTPServerTransport } from "@modelcontextprotocol/sdk/server/
62438
62852
 
62439
62853
  // ../hyperline-mcp/build/server/server.js
62440
62854
  import { McpServer } from "@modelcontextprotocol/sdk/server/mcp.js";
62855
+ var defaultToolOutputSchema = {
62856
+ result: external_exports.unknown()
62857
+ };
62441
62858
 
62442
62859
  // ../hyperline-mcp/build/session/sessionKey.js
62443
62860
  import { createHmac } from "node:crypto";