@topogram/starter-hello-api 0.1.7
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.
- package/README.md +27 -0
- package/package.json +21 -0
- package/topogram/actors/actor-client.tg +6 -0
- package/topogram/capabilities/cap-get-hello.tg +9 -0
- package/topogram/projections/proj-api.tg +14 -0
- package/topogram/shapes/shape-output-hello.tg +10 -0
- package/topogram-template.json +8 -0
- package/topogram.project.json +24 -0
package/README.md
ADDED
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
# Topogram Starter: Hello API
|
|
2
|
+
|
|
3
|
+
Package-backed Hono API-only starter for `topogram new`.
|
|
4
|
+
|
|
5
|
+
```bash
|
|
6
|
+
topogram new ./hello-api --template @topogram/starter-hello-api
|
|
7
|
+
```
|
|
8
|
+
|
|
9
|
+
## Contract
|
|
10
|
+
|
|
11
|
+
- Catalog id: `hello-api`
|
|
12
|
+
- Surfaces: `api`
|
|
13
|
+
- Generator: `@topogram/generator-hono-api`
|
|
14
|
+
- Runtime stack: Hono
|
|
15
|
+
- Executable implementation: no
|
|
16
|
+
- Purpose: API-only starter for modeling endpoint contracts without web or database output.
|
|
17
|
+
|
|
18
|
+
## First Run
|
|
19
|
+
|
|
20
|
+
```bash
|
|
21
|
+
topogram new ./hello-api --template hello-api
|
|
22
|
+
cd ./hello-api
|
|
23
|
+
npm install
|
|
24
|
+
npm run doctor
|
|
25
|
+
npm run check
|
|
26
|
+
npm run generate
|
|
27
|
+
```
|
package/package.json
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@topogram/starter-hello-api",
|
|
3
|
+
"version": "0.1.7",
|
|
4
|
+
"description": "Hono API-only Topogram starter.",
|
|
5
|
+
"license": "UNLICENSED",
|
|
6
|
+
"private": false,
|
|
7
|
+
"type": "module",
|
|
8
|
+
"files": [
|
|
9
|
+
"topogram-template.json",
|
|
10
|
+
"topogram",
|
|
11
|
+
"topogram.project.json",
|
|
12
|
+
"README.md"
|
|
13
|
+
],
|
|
14
|
+
"devDependencies": {
|
|
15
|
+
"@topogram/generator-hono-api": "0.2.6"
|
|
16
|
+
},
|
|
17
|
+
"publishConfig": {
|
|
18
|
+
"registry": "https://registry.npmjs.org",
|
|
19
|
+
"access": "public"
|
|
20
|
+
}
|
|
21
|
+
}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
projection proj_api {
|
|
2
|
+
name "Hello API"
|
|
3
|
+
description "HTTP API realization for the hello API starter"
|
|
4
|
+
platform dotnet
|
|
5
|
+
|
|
6
|
+
realizes [cap_get_hello]
|
|
7
|
+
outputs [request_contracts, response_contracts, endpoints]
|
|
8
|
+
|
|
9
|
+
http {
|
|
10
|
+
cap_get_hello method GET path /hello success 200 auth none request none
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
status active
|
|
14
|
+
}
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": "0.1",
|
|
3
|
+
"outputs": {
|
|
4
|
+
"app": {
|
|
5
|
+
"path": "./app",
|
|
6
|
+
"ownership": "generated"
|
|
7
|
+
}
|
|
8
|
+
},
|
|
9
|
+
"topology": {
|
|
10
|
+
"components": [
|
|
11
|
+
{
|
|
12
|
+
"id": "app_api",
|
|
13
|
+
"type": "api",
|
|
14
|
+
"projection": "proj_api",
|
|
15
|
+
"generator": {
|
|
16
|
+
"id": "@topogram/generator-hono-api",
|
|
17
|
+
"version": "1",
|
|
18
|
+
"package": "@topogram/generator-hono-api"
|
|
19
|
+
},
|
|
20
|
+
"port": 3000
|
|
21
|
+
}
|
|
22
|
+
]
|
|
23
|
+
}
|
|
24
|
+
}
|