Skip to content
This repository was archived by the owner on Sep 26, 2023. It is now read-only.

Commit 1481609

Browse files
committed
connect up the optic url
1 parent b3f64b1 commit 1481609

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

examples/fastify/src/app.ts

+4
Original file line numberDiff line numberDiff line change
@@ -5,13 +5,17 @@ import { Static, Type } from "@sinclair/typebox";
55
export const setupApp = async () => {
66
const app = Fastify();
77

8+
// Create an API and get an optic-url from https://app.useoptic.com
9+
const opticUrl = {'x-optic-url': 'https://app.useoptic.com/[placeholder]'} as any;
10+
811
await app.register(fastifySwagger, {
912
// Opt into OpenAPIV3 generation
1013
openapi: {
1114
info: {
1215
title: "My api spec",
1316
version: "1.0.0",
1417
},
18+
...opticUrl
1519
},
1620
});
1721

0 commit comments

Comments
 (0)