create-zuplo-api 6.16.14 → 6.17.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,29 @@
1
+ ## Zuplo API
2
+
3
+ This is a Zuplo API that was created with
4
+ [`create-zuplo-api`](https://zuplo.com/docs).
5
+
6
+ ## Getting Started
7
+
8
+ First, run the development server:
9
+
10
+ ```bash
11
+ npm run dev
12
+ # or
13
+ yarn dev
14
+ # or
15
+ pnpm dev
16
+ ```
17
+
18
+ Open [http://localhost:3000](http://localhost:3000) with your browser to see the
19
+ result.
20
+
21
+ You can start editing the API by modifying `config/routes.oas.json`. The dev
22
+ server will automatically reload the API with your changes.
23
+
24
+ ## Learn More
25
+
26
+ To learn more about Zuplo, you can visit the
27
+ [Zuplo documentation](https://zuplo.com/docs).
28
+
29
+ To connect with the community join [Discord](https://discord.zuplo.com).
@@ -0,0 +1,5 @@
1
+ {
2
+ "$schema": "https://cdn.zuplo.com/schemas/dev-portal.json",
3
+ "enabled": true,
4
+ "enableAuthentication": true
5
+ }
@@ -0,0 +1,3 @@
1
+ {
2
+ "policies": []
3
+ }
@@ -0,0 +1,8 @@
1
+ {
2
+ "openapi": "3.1.0",
3
+ "info": {
4
+ "version": "1.0.0",
5
+ "title": "My Zuplo API"
6
+ },
7
+ "paths": {}
8
+ }
@@ -0,0 +1,43 @@
1
+ # My API
2
+
3
+ You can write full markdown in these documents. Syntax highlighting and full
4
+ Github Flavored markdown are supported. To learn more about customizing the
5
+ documentation of this developer portal
6
+ [see the documentation](https://zuplo.com/docs/developer-portal/adding-pages).
7
+
8
+ ```ts
9
+ const response = await fetch("https://echo.zuplo.io", {
10
+ headers: {
11
+ "content-type": "application/json",
12
+ },
13
+ });
14
+
15
+ const data = await response.json();
16
+ console.log(data);
17
+ ```
18
+
19
+ ## Labore et Dolore
20
+
21
+ Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor
22
+ incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis
23
+ nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat.
24
+ Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu
25
+ fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in
26
+ culpa qui officia deserunt mollit anim id est laborum.
27
+
28
+ | Item | Description | Quanity |
29
+ | --------------- | -------------------------------------------- | ------- |
30
+ | ullamco laboris | reprehenderit in voluptate velit esse cillum | 21 |
31
+ | Excepteur sint | tempor incididunt ut labore | 1 |
32
+ | anim id est | irure dolor in reprehenderit in voluptate | 82 |
33
+ | non proiden | cupidatat non proident, sunt in | 53 |
34
+
35
+ ## Aliquip pariatur
36
+
37
+ Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia
38
+ deserunt mollit anim id est laborum.
39
+
40
+ - **Item 1** - ullamco laboris nisi ut aliquip ex ea commodo
41
+ - **Item 2** - ullamco laboris nisi ut aliquip ex ea commodo
42
+ - **Item 3** - ullamco laboris nisi ut aliquip ex ea commodo
43
+ - **Item 4** - ullamco laboris nisi ut aliquip ex ea commodo
@@ -0,0 +1,13 @@
1
+ {
2
+ "docs": [
3
+ {
4
+ "type": "doc",
5
+ "id": "index",
6
+ "label": "Index"
7
+ },
8
+ {
9
+ "type": "api-ref",
10
+ "label": "API Reference"
11
+ }
12
+ ]
13
+ }
@@ -0,0 +1,29 @@
1
+ /* Learn about theming here: https://zuplo.com/docs/developer-portal/theme */
2
+
3
+ :root {
4
+ --logo-url: url(https://cdn.zuplo.com/dev-portal/v2/made-with-zuplo.svg);
5
+ }
6
+
7
+ .light {
8
+ --background-primary: white;
9
+ --font-family-primary: "-apple-system", "BlinkMacSystemFont", "Segoe UI",
10
+ "Roboto", "Helvetica Neue", "Ubuntu", "sans-serif";
11
+ --text-color-h1: rgb(42 47 69);
12
+ --text-color-h2: rgb(42 47 69);
13
+ --text-color-primary: rgb(79 86 107);
14
+ }
15
+
16
+ .dark {
17
+ --background-primary: #1a1f36;
18
+ --font-family-primary: "-apple-system", "BlinkMacSystemFont", "Segoe UI",
19
+ "Roboto", "Helvetica Neue", "Ubuntu", "sans-serif";
20
+ --text-color-h1: #f7fafc;
21
+ --text-color-h2: #f7fafc;
22
+ --text-color-primary: rgb(193 201 210);
23
+ }
24
+
25
+ /* The logo image */
26
+ .theme-logo {
27
+ content: var(--logo-url);
28
+ margin: 20px;
29
+ }
@@ -0,0 +1,2 @@
1
+ EXAMPLE_SECRET=👀 What you looking at?
2
+ EXAMPLE_CONFIG=https://twitter.com/zuplo
@@ -0,0 +1,7 @@
1
+ {
2
+ "root": true,
3
+ "extends": ["eslint:recommended", "plugin:@typescript-eslint/recommended"],
4
+ "parser": "@typescript-eslint/parser",
5
+ "parserOptions": { "project": ["./tsconfig.json"] },
6
+ "plugins": ["@typescript-eslint"]
7
+ }
@@ -0,0 +1,10 @@
1
+ .zuplo/
2
+ .cache/
3
+ dist/
4
+ node_modules/
5
+ .env
6
+ .env.zuplo
7
+ .husky/_
8
+
9
+ # OS Stuff
10
+ .DS_Store
@@ -0,0 +1,21 @@
1
+ import { ZuploContext, ZuploRequest } from "@zuplo/runtime";
2
+
3
+ export default async function (request: ZuploRequest, context: ZuploContext) {
4
+ /**
5
+ * Use the log property on context to enjoy
6
+ * logging magic when testing your API.
7
+ */
8
+ context.log.info(`Hi, from inside your zup!`);
9
+
10
+ /**
11
+ * If you want to proxy an API, you can simply
12
+ * return the content of a fetch. Try it by
13
+ * uncommenting the line below.
14
+ */
15
+ // return fetch('http://www.example.com/');
16
+
17
+ /**
18
+ * In this example, we're just going to return some content.
19
+ */
20
+ return "What zup?";
21
+ }
@@ -0,0 +1 @@
1
+ {}
@@ -0,0 +1,19 @@
1
+ {
2
+ "include": ["modules/**/*", ".zuplo/**/*", "tests/**/*"],
3
+ "exclude": ["./node_modules", "./dist"],
4
+ "compilerOptions": {
5
+ "module": "ESNext",
6
+ "target": "ES2022",
7
+ "lib": ["ESNext", "WebWorker", "Webworker.Iterable"],
8
+ "preserveConstEnums": true,
9
+ "moduleResolution": "Bundler",
10
+ "useUnknownInCatchVariables": false,
11
+ "forceConsistentCasingInFileNames": true,
12
+ "importHelpers": true,
13
+ "removeComments": true,
14
+ "esModuleInterop": true,
15
+ "noEmit": true,
16
+ "strictNullChecks": true,
17
+ "experimentalDecorators": true
18
+ }
19
+ }
@@ -0,0 +1,37 @@
1
+ {
2
+ // Use IntelliSense to learn about possible attributes.
3
+ // Hover to view descriptions of existing attributes.
4
+ // For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
5
+ "version": "0.2.0",
6
+ "configurations": [
7
+ {
8
+ "type": "node",
9
+ "request": "launch",
10
+ "name": "Launch Zuplo",
11
+ "runtimeExecutable": "npx",
12
+ "runtimeArgs": [
13
+ "@zuplo/cli",
14
+ "dev",
15
+ "--debug-port",
16
+ "9229",
17
+ "--port",
18
+ "9000"
19
+ ],
20
+ "console": "integratedTerminal",
21
+ "internalConsoleOptions": "neverOpen"
22
+ },
23
+ {
24
+ "name": "Zuplo Gateway",
25
+ "type": "node",
26
+ "request": "attach",
27
+ "restart": true,
28
+ "port": 9229
29
+ }
30
+ ],
31
+ "compounds": [
32
+ {
33
+ "name": "Launch & Attach Zuplo",
34
+ "configurations": ["Launch Zuplo", "Zuplo Gateway"]
35
+ }
36
+ ]
37
+ }
@@ -0,0 +1,20 @@
1
+ {
2
+ "json.schemas": [
3
+ {
4
+ "fileMatch": ["config/*.oas.json"],
5
+ "url": "https://cdn.zuplo.com/schemas/openapi-v3.1-zuplo.json"
6
+ },
7
+ {
8
+ "fileMatch": ["config/policies.json"],
9
+ "url": "https://cdn.zuplo.com/schemas/policies.json"
10
+ },
11
+ {
12
+ "fileMatch": ["config/dev-portal.json"],
13
+ "url": "https://cdn.zuplo.com/schemas/dev-portal.json"
14
+ },
15
+ {
16
+ "fileMatch": ["docs/sidebar.json"],
17
+ "url": "https://cdn.zuplo.com/schemas/sidebar.json"
18
+ }
19
+ ]
20
+ }
@@ -0,0 +1,4 @@
1
+ {
2
+ "version": 1,
3
+ "compatibilityDate": "2024-09-02",
4
+ }
@@ -0,0 +1,3 @@
1
+ {
2
+ "policies": []
3
+ }
@@ -0,0 +1,5 @@
1
+ {
2
+ "openapi": "3.1.0",
3
+ "info": {},
4
+ "paths": {}
5
+ }
@@ -0,0 +1,2 @@
1
+ EXAMPLE_SECRET=👀 What you looking at?
2
+ EXAMPLE_CONFIG=https://twitter.com/zuplo
@@ -0,0 +1,7 @@
1
+ {
2
+ "root": true,
3
+ "extends": ["eslint:recommended", "plugin:@typescript-eslint/recommended"],
4
+ "parser": "@typescript-eslint/parser",
5
+ "parserOptions": { "project": ["./tsconfig.json"] },
6
+ "plugins": ["@typescript-eslint"]
7
+ }
@@ -0,0 +1,10 @@
1
+ .zuplo/
2
+ .cache/
3
+ dist/
4
+ node_modules/
5
+ .env
6
+ .env.zuplo
7
+ .husky/_
8
+
9
+ # OS Stuff
10
+ .DS_Store
@@ -0,0 +1,19 @@
1
+ {
2
+ "include": ["modules/**/*", ".zuplo/**/*", "tests/**/*"],
3
+ "exclude": ["./node_modules", "./dist"],
4
+ "compilerOptions": {
5
+ "module": "ESNext",
6
+ "target": "ES2022",
7
+ "lib": ["ESNext", "WebWorker", "Webworker.Iterable"],
8
+ "preserveConstEnums": true,
9
+ "moduleResolution": "Bundler",
10
+ "useUnknownInCatchVariables": false,
11
+ "forceConsistentCasingInFileNames": true,
12
+ "importHelpers": true,
13
+ "removeComments": true,
14
+ "esModuleInterop": true,
15
+ "noEmit": true,
16
+ "strictNullChecks": true,
17
+ "experimentalDecorators": true
18
+ }
19
+ }
@@ -0,0 +1,4 @@
1
+ {
2
+ "version": 1,
3
+ "compatibilityDate": "2024-09-02",
4
+ }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "create-zuplo-api",
3
- "version": "6.16.14",
3
+ "version": "6.17.0",
4
4
  "keywords": [
5
5
  "api",
6
6
  "openapi",
@@ -25,7 +25,8 @@
25
25
  ],
26
26
  "scripts": {
27
27
  "dev": "ncc build ./index.ts -w -o dist/",
28
- "build": "rm -rf ./dist && ncc build ./index.ts -o ./dist/ --minify --no-cache --no-source-map-register"
28
+ "build": "rm -rf ./dist && ncc build ./index.ts -o ./dist/ --minify --no-cache --no-source-map-register",
29
+ "build:public": "rm -rf ./dist && ncc build ./index.ts -o ./dist/ --minify --no-cache --no-source-map-register"
29
30
  },
30
31
  "devDependencies": {
31
32
  "@types/async-retry": "1.4.9",