@opusdns/api 1.12.0 → 1.13.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -3,7 +3,7 @@
3
3
  "@opusdns/api-spec-ts-generator": "^1.2.0"
4
4
  },
5
5
  "name": "@opusdns/api",
6
- "version": "1.12.0",
6
+ "version": "1.13.0",
7
7
  "description": "TypeScript types for the OpusDNS OpenAPI specification",
8
8
  "main": "./src/index.ts",
9
9
  "module": "./src/index.ts",
@@ -1549,6 +1549,7 @@ export const REPORT_TYPE = {
1549
1549
  DOMAIN_FORWARDS: "domain_forwards",
1550
1550
  EXPIRING_DOMAINS: "expiring_domains",
1551
1551
  EMAIL_FORWARDS: "email_forwards",
1552
+ REGISTRAR_PORTFOLIO_PDF: "registrar_portfolio_pdf",
1552
1553
  BILLING_TRANSACTIONS: "billing_transactions",
1553
1554
  BILLING_TRANSACTIONS_MONTHLY: "billing_transactions_monthly",
1554
1555
  } as const satisfies Record<string, ReportType>;
@@ -1560,6 +1561,7 @@ export const REPORT_TYPE_VALUES = [
1560
1561
  'domain_forwards',
1561
1562
  'expiring_domains',
1562
1563
  'email_forwards',
1564
+ 'registrar_portfolio_pdf',
1563
1565
  'billing_transactions',
1564
1566
  'billing_transactions_monthly',
1565
1567
  ] as const satisfies ReadonlyArray<ReportType>;
@@ -1048,9 +1048,11 @@ export const KEYS_CREATE_JOB_BATCH = [
1048
1048
  KEY_CREATE_JOB_BATCH_TOTAL_COMMANDS,
1049
1049
  ] as const satisfies (keyof CreateJobBatch)[];
1050
1050
 
1051
+ export const KEY_CREATE_REPORT_REQ_REGISTRAR_CREDENTIAL_ID = 'registrar_credential_id' satisfies keyof CreateReportReq;
1051
1052
  export const KEY_CREATE_REPORT_REQ_REPORT_TYPE = 'report_type' satisfies keyof CreateReportReq;
1052
1053
 
1053
1054
  export const KEYS_CREATE_REPORT_REQ = [
1055
+ KEY_CREATE_REPORT_REQ_REGISTRAR_CREDENTIAL_ID,
1054
1056
  KEY_CREATE_REPORT_REQ_REPORT_TYPE,
1055
1057
  ] as const satisfies (keyof CreateReportReq)[];
1056
1058
 
package/src/openapi.yaml CHANGED
@@ -2125,6 +2125,16 @@ components:
2125
2125
  type: object
2126
2126
  CreateReportReq:
2127
2127
  properties:
2128
+ registrar_credential_id:
2129
+ anyOf:
2130
+ - examples:
2131
+ - registrar_credential_01h45ytscbebyvny4gc8cr8ma2
2132
+ format: typeid
2133
+ pattern: ^registrar_credential_[0-7][0-9a-hjkmnpq-tv-z]{25}$
2134
+ type: string
2135
+ x-typeid-prefix: registrar_credential
2136
+ - type: 'null'
2137
+ title: Registrar Credential Id
2128
2138
  report_type:
2129
2139
  $ref: '#/components/schemas/ReportType'
2130
2140
  default: domain_inventory
@@ -9989,6 +9999,7 @@ components:
9989
9999
  - domain_forwards
9990
10000
  - expiring_domains
9991
10001
  - email_forwards
10002
+ - registrar_portfolio_pdf
9992
10003
  - billing_transactions
9993
10004
  - billing_transactions_monthly
9994
10005
  title: ReportType
@@ -12001,7 +12012,7 @@ info:
12001
12012
  \n\n"
12002
12013
  summary: OpusDNS - your gateway to a seamless domain management experience.
12003
12014
  title: OpusDNS API
12004
- version: 2026-06-11-173831
12015
+ version: 2026-06-12-154603
12005
12016
  x-logo:
12006
12017
  altText: OpusDNS API Reference
12007
12018
  url: https://d24lr4zqs1tgqh.cloudfront.net/c9505a20-5ae1-406c-b060-d392569caebf.jpg
@@ -26594,50 +26605,67 @@ tags:
26594
26605
  \ | Summary of all DNS zones and their configuration |\n| `dns_zone_records` |\
26595
26606
  \ Detailed export of all DNS records across zones |\n| `billing_transactions`\
26596
26607
  \ | Billing transactions for the current month to date |\n| `billing_transactions_monthly`\
26597
- \ | Billing transactions for the previous calendar month |\n\n### Billing Transaction\
26598
- \ Reports\n\nBilling transaction reports export all completed transactions as\
26599
- \ a CSV with the following columns: `product_reference`, `action`, `period`, `product_type`,\
26600
- \ `amount`, `currency`, `completed_on`.\n\nThere are two billing report types:\n\
26601
- \n- **`billing_transactions`** \u2014 On-demand report covering the current month\
26602
- \ to date (1st of the month through the time of the request). Request this via\
26603
- \ the API like any other report type.\n- **`billing_transactions_monthly`** \u2014\
26604
- \ Automatically generated on the 1st of each month at 5 AM UTC, covering the full\
26605
- \ previous calendar month. These are scheduled reports and do not need to be manually\
26606
- \ requested.\n\nBoth types maintain their own retention of 30 reports each, so\
26607
- \ requesting on-demand reports will not displace the monthly archive.\n\n### Report\
26608
- \ Lifecycle\n\nA report transitions through the following statuses:\n\n1. **pending**\
26609
- \ \u2014 Report has been queued for generation\n2. **generating** \u2014 Report\
26610
- \ is being built\n3. **completed** \u2014 Report is ready for download\n4. **failed**\
26611
- \ \u2014 Generation failed\n\n### Usage Pattern\n\n1. **Request a report** \u2014\
26612
- \ `POST /v1/reports` with the desired `report_type`\n2. **Poll for completion**\
26613
- \ \u2014 `GET /v1/reports/{report_id}` until `status` is `completed`\n3. **Download**\
26614
- \ \u2014 `GET /v1/reports/{report_id}/download` returns the report as a streamed\
26615
- \ ZIP file\n\n### Downloading Reports\n\n`GET /v1/reports/{report_id}/download`\
26616
- \ streams the report file directly to the client. The report **must** have status\
26617
- \ `completed` before it can be downloaded \u2014 calling this endpoint on a report\
26618
- \ that is still `pending` or `generating` returns `409 Conflict`.\n\n**Response\
26619
- \ details:**\n\n| Header | Value |\n|--------|-------|\n| `Content-Type` | `application/zip`\
26620
- \ |\n| `Content-Disposition` | `attachment; filename={report_type}-{report_id}.zip`\
26621
- \ |\n| `Content-Length` | File size in bytes (included when known) |\n\nThe response\
26622
- \ body is streamed in chunks, so clients should read the body incrementally rather\
26623
- \ than buffering it entirely in memory. When `Content-Length` is present, it can\
26624
- \ be used to display download progress.\n\n### Trigger Types\n\n| Type | Description\
26625
- \ |\n|------|-------------|\n| `on_demand` | Manually requested via the API |\n\
26626
- | `scheduled` | Automatically generated on a recurring schedule |\n\n### Rate\
26627
- \ Limiting\n\nReport creation is rate-limited at two levels:\n\n- **Cooldown**\
26628
- \ \u2014 After creating a report, you must wait **5 minutes** before requesting\
26629
- \ another report of the same type. Requests during the cooldown return `429 Too\
26630
- \ Many Requests` with a `Retry-After` header.\n- **Hourly limit** \u2014 Only\
26631
- \ **one report per type per organization per clock hour** (UTC) can be generated.\
26632
- \ Duplicate requests within the same hour will not produce an additional report.\n\
26633
- \n### Retention\n\nThe **30 most recent reports** of each type are kept per organization.\
26634
- \ Older reports and their associated files are automatically deleted when a new\
26635
- \ report is generated.\n\n### Listing Reports\n\nUse `GET /v1/reports` to list\
26636
- \ reports with optional filters:\n\n| Parameter | Description |\n|-----------|-------------|\n\
26637
- | `report_type` | Filter by report type (repeatable) |\n| `status` | Filter by\
26638
- \ report status (repeatable) |\n| `trigger_type` | Filter by trigger type |\n\
26639
- | `created_after` | Only reports created after this timestamp |\n| `created_before`\
26640
- \ | Only reports created before this timestamp |\n"
26608
+ \ | Billing transactions for the previous calendar month |\n| `registrar_portfolio_pdf`\
26609
+ \ | Credential-scoped registrar portfolio report as a PDF inside the ZIP download\
26610
+ \ |\n\n### Billing Transaction Reports\n\nBilling transaction reports export all\
26611
+ \ completed transactions as a CSV with the following columns: `product_reference`,\
26612
+ \ `action`, `period`, `product_type`, `amount`, `currency`, `completed_on`.\n\n\
26613
+ There are two billing report types:\n\n- **`billing_transactions`** \u2014 On-demand\
26614
+ \ report covering the current month to date (1st of the month through the time\
26615
+ \ of the request). Request this via the API like any other report type.\n- **`billing_transactions_monthly`**\
26616
+ \ \u2014 Automatically generated on the 1st of each month at 5 AM UTC, covering\
26617
+ \ the full previous calendar month. These are scheduled reports and do not need\
26618
+ \ to be manually requested.\n\nBoth types maintain their own retention of 30 reports\
26619
+ \ each, so requesting on-demand reports will not displace the monthly archive.\n\
26620
+ \n### Registrar Portfolio PDF Reports\n\nRegistrar portfolio reports are requested\
26621
+ \ with `POST /v1/reports` and require `registrar_credential_id`:\n\n```json\n\
26622
+ {\n \"report_type\": \"registrar_portfolio_pdf\",\n \"registrar_credential_id\"\
26623
+ : \"registrar_credential_...\"\n}\n```\n\nThe report uses registrar data from\
26624
+ \ the registrar-elements OpenSearch index, populated by the scheduled daily registrar\
26625
+ \ syncs. Report generation does not trigger a sync; it uses the most recently\
26626
+ \ synced data as-is. If the credential has no portfolio data yet (for example,\
26627
+ \ a credential created since the last sync), generation fails with an error indicating\
26628
+ \ the credential is too new to report on.\n\nThe downloaded ZIP contains `registrar-portfolio-{report_typeid}.pdf`.\
26629
+ \ Before each PDF generation, the report service loads the organization's current\
26630
+ \ available TLD list from the backend and uses it to mark TLDs in the portfolio\
26631
+ \ as available or unavailable. The first version includes the sections backed\
26632
+ \ by indexed data: portfolio overview, domains/statuses/TLDs/nameservers, TLD\
26633
+ \ availability, expiry summaries, contact validation summary, and DNS record summaries.\
26634
+ \ Additional sections that require new OpenSearch fields will be added explicitly\
26635
+ \ when those fields are indexed.\n\n### Report Lifecycle\n\nA report transitions\
26636
+ \ through the following statuses:\n\n1. **pending** \u2014 Report has been queued\
26637
+ \ for generation\n2. **generating** \u2014 Report is being built\n3. **completed**\
26638
+ \ \u2014 Report is ready for download\n4. **failed** \u2014 Generation failed\n\
26639
+ \n### Usage Pattern\n\n1. **Request a report** \u2014 `POST /v1/reports` with\
26640
+ \ the desired `report_type`\n2. **Poll for completion** \u2014 `GET /v1/reports/{report_id}`\
26641
+ \ until `status` is `completed`\n3. **Download** \u2014 `GET /v1/reports/{report_id}/download`\
26642
+ \ returns the report as a streamed ZIP file\n\n### Downloading Reports\n\n`GET\
26643
+ \ /v1/reports/{report_id}/download` streams the report file directly to the client.\
26644
+ \ The report **must** have status `completed` before it can be downloaded \u2014\
26645
+ \ calling this endpoint on a report that is still `pending` or `generating` returns\
26646
+ \ `409 Conflict`.\n\n**Response details:**\n\n| Header | Value |\n|--------|-------|\n\
26647
+ | `Content-Type` | `application/zip` |\n| `Content-Disposition` | `attachment;\
26648
+ \ filename={report_type}-{report_id}.zip` |\n| `Content-Length` | File size in\
26649
+ \ bytes (included when known) |\n\nThe response body is streamed in chunks, so\
26650
+ \ clients should read the body incrementally rather than buffering it entirely\
26651
+ \ in memory. When `Content-Length` is present, it can be used to display download\
26652
+ \ progress.\n\n### Trigger Types\n\n| Type | Description |\n|------|-------------|\n\
26653
+ | `on_demand` | Manually requested via the API |\n| `scheduled` | Automatically\
26654
+ \ generated on a recurring schedule |\n\n### Rate Limiting\n\nReport creation\
26655
+ \ is rate-limited at two levels:\n\n- **Cooldown** \u2014 After creating a report,\
26656
+ \ you must wait **5 minutes** before requesting another report of the same type.\
26657
+ \ Requests during the cooldown return `429 Too Many Requests` with a `Retry-After`\
26658
+ \ header.\n- **Hourly limit** \u2014 Only **one report per type per organization\
26659
+ \ per clock hour** (UTC) can be generated. Duplicate requests within the same\
26660
+ \ hour will not produce an additional report.\n\n### Retention\n\nThe **30 most\
26661
+ \ recent reports** of each type are kept per organization. Older reports and their\
26662
+ \ associated files are automatically deleted when a new report is generated.\n\
26663
+ \n### Listing Reports\n\nUse `GET /v1/reports` to list reports with optional filters:\n\
26664
+ \n| Parameter | Description |\n|-----------|-------------|\n| `report_type` |\
26665
+ \ Filter by report type (repeatable) |\n| `status` | Filter by report status (repeatable)\
26666
+ \ |\n| `trigger_type` | Filter by trigger type |\n| `created_after` | Only reports\
26667
+ \ created after this timestamp |\n| `created_before` | Only reports created before\
26668
+ \ this timestamp |\n"
26641
26669
  name: report
26642
26670
  x-displayName: Reports
26643
26671
  - description: Endpoints for creating new Tags
package/src/schema.d.ts CHANGED
@@ -3936,6 +3936,8 @@ export interface components {
3936
3936
  };
3937
3937
  /** CreateReportReq */
3938
3938
  CreateReportReq: {
3939
+ /** Registrar Credential Id */
3940
+ registrar_credential_id?: TypeId<"registrar_credential"> | null;
3939
3941
  /** @default domain_inventory */
3940
3942
  report_type: components["schemas"]["ReportType"];
3941
3943
  };
@@ -9010,7 +9012,7 @@ export interface components {
9010
9012
  * ReportType
9011
9013
  * @enum {string}
9012
9014
  */
9013
- ReportType: "domain_inventory" | "dns_zone_summary" | "dns_zone_records" | "domain_forwards" | "expiring_domains" | "email_forwards" | "billing_transactions" | "billing_transactions_monthly";
9015
+ ReportType: "domain_inventory" | "dns_zone_summary" | "dns_zone_records" | "domain_forwards" | "expiring_domains" | "email_forwards" | "registrar_portfolio_pdf" | "billing_transactions" | "billing_transactions_monthly";
9014
9016
  /** RequestHistory */
9015
9017
  RequestHistory: {
9016
9018
  /**