SmoliyY / api-definitions

Rebilly's public API definitions

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Rebilly OpenAPI Definitions

changes

TBD: Add Redocly validation status badge.

Links

Contributing

Read our contribution guide.

Environment setup

If you use VS Code, use the Redocly VS Code extension to edit this repo and get inline lint feedback and previews.

Install

  1. Install Node JS (version 14 or more recent)
  2. Clone repo and run npm ci in the repo root

Usage

Preview

This process describes how to start a development server docs preview for the Rebilly API docs. Changes made to the API specification while the development server is running are immediately displayed in the docs preview.

Rebilly uses Redocly to generate, manage, and preview API docs.

  1. In a terminal, install the Redocly CLI.
    Use this command to install the package globally on your machine: npm install @redocly/cli -g
  2. Sign in or create a Redocly account.
    If you are a Rebilly employee, sign in using SSO and your Rebilly email address.
  3. In Redocly, in the top right of the screen, click your name, then click My profile.
  4. In the Personal API keys section, click Add API key.
  5. Enter an API key name, then click Save.
  6. Copy the API key.
  7. In a terminal, execute the following command: redocly login.
  8. When prompted, paste your API key.
  9. Execute one of the following commands to start a development server docs preview:
    • Core API docs: redocly preview-docs core@latest
    • All API docs: redocly preview-docs all@latest
  10. In a web browser, open the preview server URL that is displayed in the terminal.

Build

Run npm run build to bundle the definitions into a single file in the dist folder.

Validate

Run npx redocly lint to validate the definitions.

About

Rebilly's public API definitions


Languages

Language:PHP 52.1%Language:JavaScript 46.1%Language:HTML 1.7%Language:Hack 0.1%