add docs, start planning this app a bit better.
This commit is contained in:
parent
5ee4d3f0d9
commit
cddbc7fa89
23
docs/api.yml
Normal file
23
docs/api.yml
Normal file
@ -0,0 +1,23 @@
|
||||
openapi: '3.0.3'
|
||||
info:
|
||||
title: Slovocast API
|
||||
description: The Slovocast internal API Service definition
|
||||
contact:
|
||||
name: Dave Smith-Hayes
|
||||
email: me@davesmithhayes.com
|
||||
url: https://slovocast.com
|
||||
version: 1.0.0
|
||||
components:
|
||||
schemas:
|
||||
User:
|
||||
type: object
|
||||
properties:
|
||||
id:
|
||||
type: integer
|
||||
format: uint64
|
||||
email:
|
||||
type: string
|
||||
format: email
|
||||
password:
|
||||
type: string
|
||||
|
16
server/src/routes/channel.ts
Normal file
16
server/src/routes/channel.ts
Normal file
@ -0,0 +1,16 @@
|
||||
import { Hono, Context } from 'hono';
|
||||
|
||||
const channelRoutes = new Hono();
|
||||
|
||||
channelRoutes.get('/:channelSlug', async (c: Context) => {
|
||||
|
||||
return c.json([
|
||||
{
|
||||
channel: {
|
||||
name: 'Something'
|
||||
}
|
||||
}
|
||||
]);
|
||||
});
|
||||
|
||||
export default channelRoutes;
|
@ -35,4 +35,14 @@ app.post('/register', async (c: Context) => {
|
||||
}
|
||||
});
|
||||
|
||||
app.post('/login', async (c: Context) => {
|
||||
|
||||
return c.json({ "success": true });
|
||||
});
|
||||
|
||||
app.post('/create/channel', async (c: Context) => {
|
||||
|
||||
return c.json({ "success": true });
|
||||
});
|
||||
|
||||
export default app;
|
||||
|
Loading…
Reference in New Issue
Block a user