UNPKG

@apisyouwonthate/style-guide

Version:

Make your HTTP APIs better, faster, stronger, whether they are still being designed (API Design-First) or your organization has flopped various mismatched APIs into production and now you're thinking some consistency would be nice. Using Spectral and Open

252 lines (249 loc) 9.17 kB
import * as _stoplight_spectral_functions from '@stoplight/spectral-functions'; import * as _stoplight_spectral_core from '@stoplight/spectral-core'; import { DiagnosticSeverity } from '@stoplight/types'; declare const _default: { rules: { "api-home": { message: string; description: string; given: string; then: { field: string; function: _stoplight_spectral_core.RulesetFunctionWithValidator<unknown, null>; }; severity: DiagnosticSeverity; }; "api-home-get": { message: string; description: string; given: string; then: { field: string; function: _stoplight_spectral_core.RulesetFunctionWithValidator<unknown, null>; }; severity: DiagnosticSeverity; }; "api-health": { message: string; description: string; given: string; then: { field: string; function: _stoplight_spectral_core.RulesetFunctionWithValidator<unknown, null>; }; severity: DiagnosticSeverity; }; "api-health-format": { message: string; description: string; formats: _stoplight_spectral_core.Format<void>[]; given: string; then: { function: _stoplight_spectral_core.RulesetFunctionWithValidator<string | number | boolean | null, _stoplight_spectral_functions.EnumerationOptions>; functionOptions: { values: string[]; }; }; severity: DiagnosticSeverity; }; "paths-kebab-case": { message: string; description: string; given: string; then: { function: _stoplight_spectral_core.RulesetFunctionWithValidator<string, _stoplight_spectral_functions.PatternOptions>; functionOptions: { match: string; }; }; severity: DiagnosticSeverity; }; "no-numeric-ids": { message: string; description: string; given: string; then: { function: _stoplight_spectral_core.RulesetFunctionWithValidator<unknown, _stoplight_spectral_functions.SchemaOptions>; functionOptions: { schema: { type: string; not: { properties: { type: { const: string; }; }; }; properties: { format: { const: string; }; }; }; }; }; severity: DiagnosticSeverity; }; "no-http-basic": { message: string; description: string; given: string; then: { field: string; function: _stoplight_spectral_core.RulesetFunctionWithValidator<string, _stoplight_spectral_functions.PatternOptions>; functionOptions: { notMatch: string; }; }; severity: DiagnosticSeverity; }; "no-x-headers": { message: string; description: string; given: string; then: { function: _stoplight_spectral_core.RulesetFunctionWithValidator<string, _stoplight_spectral_functions.PatternOptions>; functionOptions: { notMatch: string; }; }; severity: DiagnosticSeverity; }; "no-x-response-headers": { message: string; description: string; given: string; then: { function: _stoplight_spectral_core.RulesetFunctionWithValidator<string, _stoplight_spectral_functions.PatternOptions>; functionOptions: { notMatch: string; }; }; severity: DiagnosticSeverity; }; "request-GET-no-body-oas2": { message: string; description: string; given: string; then: { function: _stoplight_spectral_core.RulesetFunctionWithValidator<string, _stoplight_spectral_functions.PatternOptions>; functionOptions: { notMatch: string; }; }; severity: DiagnosticSeverity; formats: _stoplight_spectral_core.Format<void>[]; }; "request-GET-no-body-oas3": { message: string; description: string; given: string; then: { function: _stoplight_spectral_core.RulesetFunctionWithValidator<unknown, unknown>; }; formats: _stoplight_spectral_core.Format<void>[]; severity: DiagnosticSeverity; }; "hosts-https-only-oas2": { message: string; description: string; given: string; then: { function: _stoplight_spectral_core.RulesetFunctionWithValidator<unknown, _stoplight_spectral_functions.SchemaOptions>; functionOptions: { schema: { type: string; items: { type: string; const: string; }; }; }; }; severity: DiagnosticSeverity; formats: _stoplight_spectral_core.Format<void>[]; }; "hosts-https-only-oas3": { message: string; description: string; given: string; then: { function: _stoplight_spectral_core.RulesetFunctionWithValidator<string, _stoplight_spectral_functions.PatternOptions>; functionOptions: { match: string; }; }; formats: _stoplight_spectral_core.Format<void>[]; severity: DiagnosticSeverity; }; "request-support-json-oas3": { message: string; description: string; given: string; then: { function: _stoplight_spectral_core.RulesetFunctionWithValidator<unknown, _stoplight_spectral_functions.SchemaOptions>; functionOptions: { schema: { type: string; properties: { "application/json": boolean; }; required: string[]; }; }; }; formats: _stoplight_spectral_core.Format<void>[]; severity: DiagnosticSeverity; }; "no-unknown-error-format": { message: string; description: string; given: string; then: { function: _stoplight_spectral_core.RulesetFunctionWithValidator<string | number | boolean | null, _stoplight_spectral_functions.EnumerationOptions>; functionOptions: { values: string[]; }; }; formats: _stoplight_spectral_core.Format<void>[]; severity: DiagnosticSeverity; }; "no-global-versioning": { message: string; description: string; given: string; then: { function: _stoplight_spectral_core.RulesetFunctionWithValidator<string, _stoplight_spectral_functions.PatternOptions>; functionOptions: { notMatch: string; }; }; formats: _stoplight_spectral_core.Format<void>[]; severity: DiagnosticSeverity; }; "no-file-extensions-in-paths": { message: string; description: string; given: string; then: { function: _stoplight_spectral_core.RulesetFunctionWithValidator<string, _stoplight_spectral_functions.PatternOptions>; functionOptions: { notMatch: string; }; }; severity: DiagnosticSeverity; }; "no-security-schemes-defined": { message: string; description: string; given: string; then: { field: string; function: _stoplight_spectral_core.RulesetFunctionWithValidator<unknown, null>; }; formats: _stoplight_spectral_core.Format<void>[]; severity: DiagnosticSeverity; }; }; }; export { _default as default };