Skip to content
Merged
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
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@
"openapi",
"overusage",
"podsi",
"preprod",
"redoc",
"redocly",
"tbody",
Expand Down
8 changes: 8 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,14 @@ Edit the source yaml files and build the package:
yarn build
```

### Midnight GraphQL docs

The Midnight Indexer GraphQL API documentation is generated using [SpectaQL](https://github.com/anvilco/spectaql) from the schema file [`midnight-indexer-api.graphql`](midnight-indexer-api.graphql). The SpectaQL configuration is in [`spectaql.yaml`](spectaql.yaml) and the custom theme is in [`spectaql-theme/`](spectaql-theme/).

To update the GraphQL schema, download the version matching the deployed Midnight Indexer from the [Midnight Indexer repository](https://github.com/midnightntwrk/midnight-indexer/blob/main/indexer-api/graphql/) and replace the local file:

Then rebuild with `yarn bundle` (SpectaQL runs as part of the bundle step) to regenerate the docs in `docs/midnight/`.

Feel free to open PR against the `master` branch. It is a great place to start any discussion for new features and changes to the Blockfrost API.

### UI
Expand Down
25 changes: 24 additions & 1 deletion blockfrost-openapi.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ info:
url: https://opensource.org/licenses/MIT
termsOfService: https://blockfrost.io/terms
description: |
Blockfrost is an API as a service that allows users to interact with the Cardano blockchain and parts of its ecosystem.
Blockfrost is an API as a service that allows users to interact with the Cardano blockchain, Midnight blockchain, and parts of their ecosystems.

## Tokens

Expand Down Expand Up @@ -53,6 +53,12 @@ info:
<code>https://cardano-preview.blockfrost.io/api/v0</code>
</td>
</tr>
<tr>
<td>Midnight mainnet</td>
<td>
<code>https://midnight-mainnet.blockfrost.io/api/v0</code>
</td>
</tr>
<tr>
<td>InterPlanetary File System</td>
<td>
Expand Down Expand Up @@ -221,6 +227,23 @@ info:
</tr>
</tbody>
</table>


## Midnight API


The Midnight Indexer API exposes a GraphQL API that enables clients to query and subscribe to blockchain data — blocks, transactions, contracts, and wallet-related events — indexed from the Midnight blockchain.

| Service | URL | Protocol |
|---------|-----|----------|
| **Indexer HTTP API** | `https://midnight-mainnet.blockfrost.io/api/v0` | HTTP POST (GraphQL) |
| **Indexer Subscriptions API** | `wss://midnight-mainnet.blockfrost.io/api/v0/ws` | WebSocket |
| **Node RPC** | `https://rpc.midnight-mainnet.blockfrost.io` | JSON-RPC |


For the full documentation — queries, mutations, subscriptions, authentication options, and examples — see the Midnight GraphQL API Reference:

[![Explore the Midnight API →](https://img.shields.io/badge/Explore_the_Midnight_API_→-0033AD?style=for-the-badge)](./midnight/)
servers:
- url: https://cardano-mainnet.blockfrost.io/api/v0
description: Cardano Mainnet network
Expand Down
41 changes: 40 additions & 1 deletion docs/blockfrost-openapi.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ info:
termsOfService: 'https://blockfrost.io/terms'
description: >
Blockfrost is an API as a service that allows users to interact with the
Cardano blockchain and parts of its ecosystem.
Cardano blockchain, Midnight blockchain, and parts of their ecosystems.


## Tokens
Expand Down Expand Up @@ -63,6 +63,12 @@ info:
<code>https://cardano-preview.blockfrost.io/api/v0</code>
</td>
</tr>
<tr>
<td>Midnight mainnet</td>
<td>
<code>https://midnight-mainnet.blockfrost.io/api/v0</code>
</td>
</tr>
<tr>
<td>InterPlanetary File System</td>
<td>
Expand Down Expand Up @@ -294,6 +300,39 @@ info:
</tr>
</tbody>
</table>



## Midnight API



The Midnight Indexer API exposes a GraphQL API that enables clients to query
and subscribe to blockchain data — blocks, transactions, contracts, and
wallet-related events — indexed from the Midnight blockchain.


| Service | URL | Protocol |

|---------|-----|----------|

| **Indexer HTTP API** | `https://midnight-mainnet.blockfrost.io/api/v0` |
HTTP POST (GraphQL) |

| **Indexer Subscriptions API** |
`wss://midnight-mainnet.blockfrost.io/api/v0/ws` | WebSocket |

| **Node RPC** | `https://rpc.midnight-mainnet.blockfrost.io` | JSON-RPC |



For the full documentation — queries, mutations, subscriptions,
authentication options, and examples — see the Midnight GraphQL API
Reference:


[![Explore the Midnight API
→](https://img.shields.io/badge/Explore_the_Midnight_API_→-0033AD?style=for-the-badge)](./midnight/)
servers:
- url: 'https://cardano-mainnet.blockfrost.io/api/v0'
description: Cardano Mainnet network
Expand Down
Binary file added docs/midnight/images/favicon.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/midnight/images/logo.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Loading