Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
2 changes: 0 additions & 2 deletions .env.example

This file was deleted.

8 changes: 1 addition & 7 deletions .github/CODEOWNERS
Original file line number Diff line number Diff line change
@@ -1,8 +1,2 @@
# Default owners of the repository
* @dyte-in/docs

# Owners for JS, JSX, TS, and TSX files
*.js @dyte-in/web
*.jsx @dyte-in/web
*.ts @dyte-in/web
*.tsx @dyte-in/web
* @BrickeVD
2 changes: 1 addition & 1 deletion .github/ISSUE_TEMPLATE/bug-report.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ body:
- type: checkboxes
attributes:
label: Are you certain it's a bug?
description: If you're uncertain, feel free to ping us at support@dyte.io
description: If you're uncertain, open a discussion instead of a bug report.
options:
- label: Yes, it looks like a bug
required: true
Expand Down
4 changes: 2 additions & 2 deletions .github/ISSUE_TEMPLATE/config.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
blank_issues_enabled: false
contact_links:
- name: Question
url: mailto:support@dyte.io
about: Please ask and answer questions on our support email.
url: https://github.com/BrickeVD/OSPI-APIdocs/discussions
about: Please ask and answer questions here.
29 changes: 0 additions & 29 deletions .github/workflows/docsearch.yml

This file was deleted.

1 change: 0 additions & 1 deletion .prettierignore
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
# autogenerated files
docs/*ui-kit/reference/**/*.md
*.min.css

LICENSE
788 changes: 7 additions & 781 deletions CHANGELOG.md

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion CODE_OF_CONDUCT.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
# Code of Conduct

All Dyte repos are governed by our Community Participation Guidelines, available at: https://dyte.notion.site/dyte/Dyte-Community-Participation-Guidelines-CPG-4b3af58fdf3545c2a3065773a9154728
This repository is governed by a standard Contributor Covenant-style code of conduct: participate in good faith, be respectful, and follow the [Contributing guide](./CONTRIBUTING.md).
156 changes: 37 additions & 119 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,181 +1,99 @@
<!-- PROJECT LOGO -->
<p align="center">
<a href="https://dyte.io">
<img src="https://assets.dyte.io/logo-outlined.png" alt="Logo" width="120">
</a>

<h2 align="center">Dyte Docs</h3>
<h2 align="center">OSPI Docs</h2>

<p align="center">
Dyte's documentation portal, built with Docusaurus.
<br />
<a href="https://docs.dyte.io"><strong>Explore the docs »</strong></a>
Documentation portal for OSPI (Open Standard Product Identification), built with Docusaurus.
<br />
<br />
<a href="https://app.dyte.io">View Demo</a>
·
<a href="https://github.com/dyte-io/docs/issues">Report Bug</a>
<a href="https://github.com/BrickeVD/ospi-platform">Platform source</a>
·
<a href="https://github.com/dyte-io/docs/issues">Request Feature</a>
<a href="https://github.com/BrickeVD/OSPI-APIdocs/issues">Report an issue</a>
</p>
</p>

<!-- TABLE OF CONTENTS -->

## Table of Contents

- [About the Project](#about-the-project)
- [Built With](#built-with)
- [Getting Started](#getting-started)
- [Prerequisites](#prerequisites)
- [Installation](#installation)
- [Usage](#usage)
- [Version History](#version-history)
- [Roadmap](#roadmap)
- [Content structure](#content-structure)
- [Contributing](#contributing)
- [Support](#support)
- [License](#license)
- [About](#about)

<!-- ABOUT THE PROJECT -->

## About The Project

[Docusaurus](https://docusaurus.io/) is a static site generator that helps you ship beautiful, accessible docs. For building our [documentation](https://docs.dyte.io) portal, we have made certain modifications over the template generated by [Docusaurus](https://docusaurus.io) to be able to properly showcase all our SDKs with their respective versions.
This is the documentation site for **OSPI (Open Standard Product Identification)** — an open standard and API platform for product identity, master data, and cross-organization product data exchange. It documents the real, running reference implementation at [`ospi-platform`](https://github.com/BrickeVD/ospi-platform): guides, a full REST API reference, and the architecture decisions behind how the platform is built.

We are delighted to see our documentation featured on [Docusaurus Site Showcase](https://docusaurus.io/showcase), and hope you like it!
All content is sourced from the actual `ospi-platform` codebase (controllers, DTOs, ADRs, domain docs) — not invented. Where the platform has an open question or a "not built yet," the docs say so.

### Built With

- [Docusaurus](https://docusaurus.io/)
- [React](https://reactjs.org/)
- [Tailwind](https://tailwindcss.com/)
- [Tailwind CSS](https://tailwindcss.com/)

<!-- GETTING STARTED -->

## Getting Started

This section describes how you can get our documentation portal up and running on your machine.

### Prerequisites

- [node](https://nodejs.org/en/)
- [npm](https://www.npmjs.com/)
- [Node.js](https://nodejs.org/en/) ≥ 18
- npm

### Installation

1. Clone the repo

```sh
git clone https://github.com/dyte-io/docs.git
```

2. Install NPM packages

```sh
git clone https://github.com/BrickeVD/OSPI-APIdocs.git
cd OSPI-APIdocs
npm install
```

3. Run the app

```sh
npm start
```

<!-- USAGE EXAMPLES -->
## Content structure

## Usage
The site is three separate Docusaurus doc instances, defined in [`docusaurus.config.js`](./docusaurus.config.js):

<!-- In usage, mention how to edit the docs, how to update versions, etc. -->
| Instance | Path | Route | Content |
| --- | --- | --- | --- |
| `guides` | `docs/guides` | `/guides` | Introduction, quickstart, authentication, core concepts, errors, idempotency/rate limits, webhooks, roles |
| `api-reference` | `docs/api-reference` | `/api-reference` | Hand-written domain guides (**Guides**) + a live, generated per-endpoint reference with request/response schemas and a "Try It" console (**Endpoints**) |
| `architecture` | `docs/architecture` | `/architecture` | Domain model + all 34 Architecture Decision Records, ported from `ospi-platform/docs/adr` |

### Writing Documentation
Branding (`src/css/custom.css`, `static/logo/`) uses a placeholder pink wordmark — the real OSPI logo and full brand guidelines were not available at the time this site was built; swap `static/logo/light.svg` and `static/logo/dark.svg` once they are.

To just edit older documentation, go to the specified versioned folder for a section, for example, you want to edit documentation for React SDK v0.25.x, open up [react_versioned_docs/version-0.25.x](./react_versioned_docs/version-0.25.x) and edit the required files there.
### Regenerating the API Reference (Endpoints) from the real backend

To create a new version inside a section, for example, flutter. Make your changes in [docs/flutter](./docs/flutter). The `./docs` folder consists of the `next` version, which is unpublished, and is where you add your newer or _next_ version of documentation.

After your changes are done, to create a version, run the following command:
The **Endpoints** pages under `/api-reference` are not hand-written — they're generated by
[`docusaurus-plugin-openapi-docs`](https://github.com/PaloAltoNetworks/docusaurus-openapi-docs) from
[`openapi/ospi-platform.json`](./openapi/ospi-platform.json), a real OpenAPI 3 document exported from the
actual [`ospi-platform`](https://github.com/BrickeVD/ospi-platform) NestJS backend's own `SwaggerModule`
(the same document it serves at `/api/docs-json`), not written by hand. To refresh it after the backend's
API surface changes:

```sh
npm run docusaurus docs:version:flutter 1.2.3
```

This will create a new version `1.2.3` for flutter.

Reference: https://docusaurus.io/docs/versioning

### To add new sections

Create a new section in docusaurus by adding a new plugin entry in [docusaurus.config.js](./docusaurus.config.js).

If you're adding a new section, just add new section to `SECTIONS[]` array with the `defineSection()` utility easily.

Now, run `npm start` and you can access your Go docs at http://localhost:3000/go/introduction
# In a clone of ospi-platform, with Postgres + Redis reachable per its own README:
npx ts-node -T scripts/generate-openapi.ts # writes openapi.json (see that script; not committed there)

Then, you can create versions and edit older versions as mentioned above.

### Adding new docs to the Context Switcher

To add a newly created section to the Sections Menu, edit [./src/sections.js](src/sections.js).

For example, for a section go, you will add:

```jsx
import { GoIcon } from '../assets/icons';

const SECTIONS = [
// ...
{
id: 'go',
name: 'Go',
icon: GoIcon,
section: false, // if it shouldn't have a sections menu
},
];
# Back in this repo:
cp path/to/ospi-platform/openapi.json openapi/ospi-platform.json
npm run gen-api-docs # regenerates docs/api-reference/reference/**
npm run build # verify
```

You'll need to create a GoIcon component too.

That is it!

<!-- CHANGELOG -->

## Version History

See [CHANGELOG](./CHANGELOG.md).

<!-- ROADMAP -->

## Roadmap

See the [open issues](https://github.com/dyte-io/docs/issues) for a list of proposed features (and known issues).

<!-- CONTRIBUTING -->
`scripts/generate-openapi.ts` boots the real Nest application (so Postgres/Redis must be reachable) and
dumps `SwaggerModule.createDocument(...)` to disk instead of calling `app.listen()`. It lives in
`ospi-platform`, not here — it's a one-off export script for that backend, not a doc-site build step.

## Contributing

Contributions are what make the open source community such an amazing place to be learn, inspire, and create. Any contributions you make are **greatly appreciated**. Sincere thanks to all our contributors. Thank you, [contributors](https://github.com/dyte-io/docs/graphs/contributors)!

You are requested to follow the contribution guidelines specified in [CONTRIBUTING.md](./CONTRIBUTING.md) and code of conduct at [CODE_OF_CONDUCT.md](./CODE_OF_CONDUCT.md) while contributing to the project :smile:.

## Support

Contributions, issues, and feature requests are welcome!
Give a ⭐️ if you like this project!

<!-- LICENSE -->
See [CONTRIBUTING.md](./CONTRIBUTING.md) and [CODE_OF_CONDUCT.md](./CODE_OF_CONDUCT.md).

## License

Distributed under the Apache License, Version 2.0. See [`LICENSE`](./LICENSE) for more information.

<!-- MARKDOWN LINKS & IMAGES -->
<!-- https://www.markdownguide.org/basic-syntax/#reference-style-links -->

## About

`docs` is created & maintained by Dyte, Inc. You can find us on Twitter - [@dyte_io](https://twitter.com/dyte_io) or write to us at `dev [at] dyte.io`.

The names and logos for Dyte are trademarks of Dyte, Inc.

We love open source software! See [our other projects](https://github.com/dyte-io) and [our products](https://dyte.io).
Loading