@apifreaks/openapi-specs 0.3.1 → 0.4.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/dist/index.d.cts CHANGED
@@ -21,6 +21,11 @@ interface OpenAPISpec {
21
21
 
22
22
  declare const SPECS: Record<string, OpenAPISpec>;
23
23
  declare const SPEC_SLUGS: string[];
24
+ /**
25
+ * YAML text for each spec, pre-rendered at build time so consumers never
26
+ * pay a runtime YAML-dump cost.
27
+ */
28
+ declare const SPECS_YAML: Record<string, string>;
24
29
  declare const SPEC_CATEGORIES: string[];
25
30
  declare const SPECS_BY_CATEGORY: Record<string, string[]>;
26
31
  /**
@@ -41,7 +46,6 @@ declare const SpecSlug: {
41
46
  readonly BULK_IP_LOOKUP: "bulk-ip-lookup";
42
47
  readonly BULK_IP_THREAT_INTELLIGENCE: "bulk-ip-threat-intelligence";
43
48
  readonly BULK_LIVE_WEATHER: "bulk-live-weather";
44
- readonly BULK_PDF_GENERATOR: "bulk-pdf-generator";
45
49
  readonly BULK_PHONE_NUMBER_VALIDATION: "bulk-phone-number-validation";
46
50
  readonly BULK_SCREENSHOT: "bulk-screenshot";
47
51
  readonly BULK_USER_AGENT_PARSER: "bulk-user-agent-parser";
@@ -65,8 +69,10 @@ declare const SpecSlug: {
65
69
  readonly DELETE_PDF_PAGE: "delete-pdf-page";
66
70
  readonly DNS_HISTORY_LOOKUP: "dns-history-lookup";
67
71
  readonly DNS_LOOKUP: "dns-lookup";
72
+ readonly DOMAIN_REPUTATION: "domain-reputation";
68
73
  readonly DOMAIN_SEARCH: "domain-search";
69
74
  readonly DOMAIN_SEARCH_WITH_SUGGESTIONS: "domain-search-with-suggestions";
75
+ readonly DOMAIN_TYPOSQUATTING: "domain-typosquatting";
70
76
  readonly DOMAIN_WHOIS_HISTORY_LOOKUP: "domain-whois-history-lookup";
71
77
  readonly EMAIL_CHECKER: "email-checker";
72
78
  readonly FINANCIAL_APIS_SUPPORTED_COUNTRIES: "financial-apis-supported-countries";
@@ -94,20 +100,21 @@ declare const SpecSlug: {
94
100
  readonly PDF_FILE_STATUS: "pdf-file-status";
95
101
  readonly PDF_FILES: "pdf-files";
96
102
  readonly PDF_GENERATOR: "pdf-generator";
103
+ readonly PDF_GENERATOR_BULK: "pdf-generator-bulk";
97
104
  readonly PDF_RESOURCE_DOWNLOAD: "pdf-resource-download";
98
105
  readonly PDF_RESOURCE_UPLOAD: "pdf-resource-upload";
99
106
  readonly PDF_RESOURCE_UPLOAD_BINARY: "pdf-resource-upload-binary";
100
107
  readonly PDF_RESTRICT: "pdf-restrict";
101
- readonly PDF_SPLIT_PAGES: "pdf-split-pages";
102
108
  readonly PDF_TASK_STATUS: "pdf-task-status";
103
109
  readonly PDF_TO_IMAGE: "pdf-to-image";
104
110
  readonly PDF_UNRESTRICT: "pdf-unrestrict";
105
- readonly PHONE_NUMBER_VALIDATION: "phone-number-validation";
111
+ readonly PHONE_VALIDATION: "phone-validation";
106
112
  readonly REGIONS: "regions";
107
113
  readonly REVERSE_DNS_LOOKUP: "reverse-dns-lookup";
108
114
  readonly REVERSE_GEOCODING: "reverse-geocoding";
109
115
  readonly REVERSE_WHOIS: "reverse-whois";
110
116
  readonly ROTATE_PDF_PAGES: "rotate-pdf-pages";
117
+ readonly SPLIT_PDF: "split-pdf";
111
118
  readonly SSL_CERTIFICATE_CHAIN_LOOKUP: "ssl-certificate-chain-lookup";
112
119
  readonly SSL_CERTIFICATE_LOOKUP: "ssl-certificate-lookup";
113
120
  readonly SUBDOMAIN_LOOKUP: "subdomain-lookup";
@@ -150,7 +157,7 @@ declare const SpecCategory: {
150
157
  readonly GEOGRAPHY: "geography";
151
158
  readonly IP_INTELLIGENCE: "ip-intelligence";
152
159
  readonly PDF: "pdf";
153
- readonly PHONE_VALIDATION: "phone-validation";
160
+ readonly PHONE_NUMBER_VALIDATION: "phone-number-validation";
154
161
  readonly SCRAPER: "scraper";
155
162
  readonly SCREENSHOT: "screenshot";
156
163
  readonly SSL: "ssl";
@@ -162,7 +169,8 @@ declare const SpecCategory: {
162
169
  };
163
170
  type SpecCategoryValue = (typeof SpecCategory)[keyof typeof SpecCategory];
164
171
 
165
- declare function getSpec(slug: SpecSlugValue | (string & {})): OpenAPISpec | undefined;
172
+ declare function getSpecJson(slug: SpecSlugValue | (string & {})): OpenAPISpec | undefined;
173
+ declare function getSpecYaml(slug: SpecSlugValue | (string & {})): string | undefined;
166
174
  declare function getSpecsByCategory(category: SpecCategoryValue | (string & {})): string[];
167
175
 
168
- export { type OpenAPISpec, SPECS, SPECS_BY_CATEGORY, SPEC_CATEGORIES, SPEC_SLUGS, SpecCategory, type SpecCategoryValue, SpecSlug, type SpecSlugValue, getSpec, getSpecsByCategory };
176
+ export { type OpenAPISpec, SPECS, SPECS_BY_CATEGORY, SPECS_YAML, SPEC_CATEGORIES, SPEC_SLUGS, SpecCategory, type SpecCategoryValue, SpecSlug, type SpecSlugValue, getSpecJson, getSpecYaml, getSpecsByCategory };
package/dist/index.d.ts CHANGED
@@ -21,6 +21,11 @@ interface OpenAPISpec {
21
21
 
22
22
  declare const SPECS: Record<string, OpenAPISpec>;
23
23
  declare const SPEC_SLUGS: string[];
24
+ /**
25
+ * YAML text for each spec, pre-rendered at build time so consumers never
26
+ * pay a runtime YAML-dump cost.
27
+ */
28
+ declare const SPECS_YAML: Record<string, string>;
24
29
  declare const SPEC_CATEGORIES: string[];
25
30
  declare const SPECS_BY_CATEGORY: Record<string, string[]>;
26
31
  /**
@@ -41,7 +46,6 @@ declare const SpecSlug: {
41
46
  readonly BULK_IP_LOOKUP: "bulk-ip-lookup";
42
47
  readonly BULK_IP_THREAT_INTELLIGENCE: "bulk-ip-threat-intelligence";
43
48
  readonly BULK_LIVE_WEATHER: "bulk-live-weather";
44
- readonly BULK_PDF_GENERATOR: "bulk-pdf-generator";
45
49
  readonly BULK_PHONE_NUMBER_VALIDATION: "bulk-phone-number-validation";
46
50
  readonly BULK_SCREENSHOT: "bulk-screenshot";
47
51
  readonly BULK_USER_AGENT_PARSER: "bulk-user-agent-parser";
@@ -65,8 +69,10 @@ declare const SpecSlug: {
65
69
  readonly DELETE_PDF_PAGE: "delete-pdf-page";
66
70
  readonly DNS_HISTORY_LOOKUP: "dns-history-lookup";
67
71
  readonly DNS_LOOKUP: "dns-lookup";
72
+ readonly DOMAIN_REPUTATION: "domain-reputation";
68
73
  readonly DOMAIN_SEARCH: "domain-search";
69
74
  readonly DOMAIN_SEARCH_WITH_SUGGESTIONS: "domain-search-with-suggestions";
75
+ readonly DOMAIN_TYPOSQUATTING: "domain-typosquatting";
70
76
  readonly DOMAIN_WHOIS_HISTORY_LOOKUP: "domain-whois-history-lookup";
71
77
  readonly EMAIL_CHECKER: "email-checker";
72
78
  readonly FINANCIAL_APIS_SUPPORTED_COUNTRIES: "financial-apis-supported-countries";
@@ -94,20 +100,21 @@ declare const SpecSlug: {
94
100
  readonly PDF_FILE_STATUS: "pdf-file-status";
95
101
  readonly PDF_FILES: "pdf-files";
96
102
  readonly PDF_GENERATOR: "pdf-generator";
103
+ readonly PDF_GENERATOR_BULK: "pdf-generator-bulk";
97
104
  readonly PDF_RESOURCE_DOWNLOAD: "pdf-resource-download";
98
105
  readonly PDF_RESOURCE_UPLOAD: "pdf-resource-upload";
99
106
  readonly PDF_RESOURCE_UPLOAD_BINARY: "pdf-resource-upload-binary";
100
107
  readonly PDF_RESTRICT: "pdf-restrict";
101
- readonly PDF_SPLIT_PAGES: "pdf-split-pages";
102
108
  readonly PDF_TASK_STATUS: "pdf-task-status";
103
109
  readonly PDF_TO_IMAGE: "pdf-to-image";
104
110
  readonly PDF_UNRESTRICT: "pdf-unrestrict";
105
- readonly PHONE_NUMBER_VALIDATION: "phone-number-validation";
111
+ readonly PHONE_VALIDATION: "phone-validation";
106
112
  readonly REGIONS: "regions";
107
113
  readonly REVERSE_DNS_LOOKUP: "reverse-dns-lookup";
108
114
  readonly REVERSE_GEOCODING: "reverse-geocoding";
109
115
  readonly REVERSE_WHOIS: "reverse-whois";
110
116
  readonly ROTATE_PDF_PAGES: "rotate-pdf-pages";
117
+ readonly SPLIT_PDF: "split-pdf";
111
118
  readonly SSL_CERTIFICATE_CHAIN_LOOKUP: "ssl-certificate-chain-lookup";
112
119
  readonly SSL_CERTIFICATE_LOOKUP: "ssl-certificate-lookup";
113
120
  readonly SUBDOMAIN_LOOKUP: "subdomain-lookup";
@@ -150,7 +157,7 @@ declare const SpecCategory: {
150
157
  readonly GEOGRAPHY: "geography";
151
158
  readonly IP_INTELLIGENCE: "ip-intelligence";
152
159
  readonly PDF: "pdf";
153
- readonly PHONE_VALIDATION: "phone-validation";
160
+ readonly PHONE_NUMBER_VALIDATION: "phone-number-validation";
154
161
  readonly SCRAPER: "scraper";
155
162
  readonly SCREENSHOT: "screenshot";
156
163
  readonly SSL: "ssl";
@@ -162,7 +169,8 @@ declare const SpecCategory: {
162
169
  };
163
170
  type SpecCategoryValue = (typeof SpecCategory)[keyof typeof SpecCategory];
164
171
 
165
- declare function getSpec(slug: SpecSlugValue | (string & {})): OpenAPISpec | undefined;
172
+ declare function getSpecJson(slug: SpecSlugValue | (string & {})): OpenAPISpec | undefined;
173
+ declare function getSpecYaml(slug: SpecSlugValue | (string & {})): string | undefined;
166
174
  declare function getSpecsByCategory(category: SpecCategoryValue | (string & {})): string[];
167
175
 
168
- export { type OpenAPISpec, SPECS, SPECS_BY_CATEGORY, SPEC_CATEGORIES, SPEC_SLUGS, SpecCategory, type SpecCategoryValue, SpecSlug, type SpecSlugValue, getSpec, getSpecsByCategory };
176
+ export { type OpenAPISpec, SPECS, SPECS_BY_CATEGORY, SPECS_YAML, SPEC_CATEGORIES, SPEC_SLUGS, SpecCategory, type SpecCategoryValue, SpecSlug, type SpecSlugValue, getSpecJson, getSpecYaml, getSpecsByCategory };