Commit Graph

63 Commits

Author SHA1 Message Date
Oliver Eyton-Williams
5482650dd0
feat(api): project-completed (#50701)
Co-authored-by: Mrugesh Mohapatra <1884376+raisedadead@users.noreply.github.com>
Co-authored-by: Niraj Nandish <nirajnandish@icloud.com>
2023-07-17 12:03:17 +04:00
renovate[bot]
8dea66d7b0 chore(deps): update dependency @fastify/type-provider-typebox to v3.3.0 2023-07-15 06:24:25 +00:00
Oliver Eyton-Williams
6e787d3336
feat(api): add /user/get-session-user (#50557)
Co-authored-by: Shaun Hamilton <shauhami020@gmail.com>
2023-07-11 16:28:56 +00:00
renovate[bot]
03323180fd chore(deps): update jest monorepo to v29.6.1 2023-07-09 04:51:55 +00:00
renovate[bot]
9105945b97 fix(deps): update dependency jsonwebtoken to v9.0.1 2023-07-09 00:13:51 +00:00
renovate[bot]
c5c02ce8a9 fix(deps): update dependency fastify to v4.19.2 2023-07-08 19:34:31 +00:00
renovate[bot]
8512ef948a chore(deps): update dependency pino-pretty to v10.0.1 2023-07-08 12:07:19 +00:00
renovate[bot]
10204613b9 fix(deps): update dependency fastify to v4.19.1 2023-07-02 18:44:15 +00:00
renovate[bot]
c94cd4e58e fix(deps): update dependency fastify to v4.19.0 2023-07-02 07:37:56 +00:00
renovate[bot]
8763713907 fix(deps): update prisma monorepo to v4.16.2 2023-07-02 01:49:34 +00:00
renovate[bot]
986fa8c9a1 chore(deps): update dependency ts-jest to v29.1.1 2023-07-01 12:03:02 +00:00
renovate[bot]
e6b88035cf
fix(deps): update dependency jsonwebtoken to v9 [security] (#50837)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2023-06-30 17:36:48 +05:30
Oliver Eyton-Williams
16c0949a4b
feat(api): user/user-token (#50721)
Co-authored-by: Shaun Hamilton <shauhami020@gmail.com>
2023-06-29 10:36:44 +00:00
renovate[bot]
ca581d395c fix(deps): update prisma monorepo to v4.16.1 2023-06-25 07:52:07 +00:00
renovate[bot]
99782e4ede fix(deps): update dependency fastify to v4.18.0 2023-06-11 03:56:47 +00:00
Oliver Eyton-Williams
65239ee68b
feat(api): allow redirection with message (#50525)
Co-authored-by: Muhammed Mustafa <MuhammedElruby@gmail.com>
2023-06-07 15:30:12 +02:00
renovate[bot]
b16f7fe042 fix(deps): update prisma monorepo to v4.15.0 2023-06-04 01:52:16 +00:00
Sem Bauke
c5deeccd3f
feat: update my username endpoint (#50271)
Co-authored-by: Oliver Eyton-Williams <ojeytonwilliams@gmail.com>
2023-06-02 07:04:50 +02:00
Oliver Eyton-Williams
39857b5aa4
test(api): schema security (#50413)
* test: confirm all schemas pass basic validation

* refactor: use tested schemas in routes

* chore: move ajv to dev deps
2023-05-24 09:31:13 -07:00
renovate[bot]
78f31aa966 fix(deps): update prisma monorepo to v4.14.1 2023-05-20 15:42:06 +00:00
Oliver Eyton-Williams
c3c912db07
feat(api): add csrf protection (#50275)
Co-authored-by: Sboonny <muhammed@freecodecamp.org>
2023-05-18 17:06:40 +05:30
renovate[bot]
0fef335292
fix(deps): update dependency @immobiliarelabs/fastify-sentry to v6 (#50388)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2023-05-16 15:21:28 -07:00
renovate[bot]
dd7e7b58f2
fix(deps): update dependency @fastify/middie to 8.3 (#50384)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2023-05-15 13:43:53 +03:00
renovate[bot]
decb2e87b6
fix(deps): update dependency fastify to v4.17.0 (#50230)
* fix(deps): update dependency fastify to v4.17.0

* add missing code in error object

---------

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Sboonny <muhammed@freecodecamp.org>
2023-05-15 11:17:09 +03:00
renovate[bot]
e2716c35ea
fix(deps): update prisma monorepo to v4.14.0 (#50377)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2023-05-15 11:12:59 +03:00
renovate[bot]
427414a24b chore(deps): update dependency @fastify/type-provider-typebox to v3.2.0 2023-05-07 08:05:16 +00:00
renovate[bot]
dd931ab4a1 fix(deps): update dependency @fastify/middie to 8.2 2023-05-07 05:43:12 +00:00
Oliver Eyton-Williams
7572f99f74
refactor(api): remove unused endpoints (#50252)
Also adds "dev" as an alias because I keep trying to use it.
2023-05-02 19:54:05 +03:00
Oliver Eyton-Williams
1567894c36
fix(api): use connection string from .env (#50201) 2023-04-27 23:06:43 +01:00
renovate[bot]
cf8dc73fae fix(deps): update prisma monorepo to v4.13.0 2023-04-27 05:32:16 +00:00
renovate[bot]
998069441e chore(deps): update dependency @fastify/type-provider-typebox to v3.1.0 2023-04-23 22:27:54 +00:00
Muhammed Mustafa
daa23a3d83
feat(api): swap to immobiliarelabs sentry plugin (#50041) 2023-04-17 13:10:23 -07:00
renovate[bot]
59743ad3fb fix(deps): update dependency @sentry/node to v7.48.0 2023-04-15 22:45:37 +00:00
renovate[bot]
9d3bf49ed8
fix(deps): update prisma monorepo to v4.12.0 (#50018)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2023-04-10 19:26:23 +05:30
renovate[bot]
ad1ba2e982 fix(deps): update dependency @sentry/node to v7.47.0 2023-04-09 13:58:10 +00:00
renovate[bot]
5b2c82d29f chore(deps): update dependency ts-jest to v29.1.0 2023-04-09 03:31:24 +00:00
Muhammed Mustafa
1d8e9fb0b7
feat(api): create sentry plugin (#49731)
* feat(api): add sentry plugin

Apply suggestions from code review

Revert "feat(api): add sentry plugin"

This reverts commit fcde4ee03e9b83e335a6a2bccd490490e9993597.

install sentryNode

WIP: create sentry debug

WIP: find out why use errorhandler isn't typed correct

install sentry

add the deleted sentry code

create sentry plugin

* fix error found through sentry

* Polish sentry plugin

Co-authored-by: Niraj Nandish <nirajnandish@icloud.com>

* duplicate the changes made in the other plugin

* add done to seterrorHandler

* Fix a typo in sentry option

Co-authored-by: Naomi Carrigan <nhcarrigan@gmail.com>

* Stop the dns from running if a DSN wasn't provided

Co-authored-by: Naomi Carrigan <nhcarrigan@gmail.com>

* Polish the function and check the variable value

Co-authored-by: Oliver Eyton-Williams <ojeytonwilliams@gmail.com>

* check the dsn dashboard in the env

* export dsn value if it isn't sentrydashboard

Co-authored-by: Naomi Carrigan <nhcarrigan@gmail.com>

* when the value is undefined init errors

* revert the if statement

* throw an error whenever an environment variable is not right

---------

Co-authored-by: Niraj Nandish <nirajnandish@icloud.com>
Co-authored-by: Naomi Carrigan <nhcarrigan@gmail.com>
Co-authored-by: Oliver Eyton-Williams <ojeytonwilliams@gmail.com>
2023-04-05 08:35:23 -07:00
renovate[bot]
b48d12714a
fix(deps): update dependency @sinclair/typebox to v0.26.6 (#49855)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Oliver Eyton-Williams <ojeytonwilliams@gmail.com>
2023-04-03 09:13:36 +00:00
Oliver Eyton-Williams
06d4076a45
feat(api): dev login (#49880)
Co-authored-by: Mrugesh Mohapatra <hi@mrugesh.dev>
2023-03-29 18:08:38 +05:30
Oliver Eyton-Williams
a128dd8fcd
chore(api): compile TS into /dist (#49812
* chore: compile TS into /dist

Having the output co-located with the source meant that the js would be
imported by default. Given that we don't recompile on source changes,
this means the server got 'stuck' at the point of compilation and would
only register changes on build.

Also, compiling to a dist directory should make it easier to build when
we want to deploy. That said, the motivation is mostly DX.

* fix: put schema.prisma in the default location
2023-03-28 19:42:20 +05:30
renovate[bot]
afa246942e fix(deps): update dependency fastify to v4.15.0 2023-03-26 15:59:50 +00:00
renovate[bot]
7f21c5b4ae fix(deps): update dependency nodemon to v2.0.22 2023-03-26 03:01:14 +00:00
Niraj Nandish
1dcba784fd
feat(api): API documentation with Swagger UI (#49791) 2023-03-24 10:00:51 +01:00
Oliver Eyton-Williams
a0f958189e
chore: update api test suite and include it in run test (#49794) 2023-03-23 16:57:11 +00:00
Oliver Eyton-Williams
36b06be8ce
chore: extend lint:ts to cover api (#49793)
* fix: include express-session types + suppress err

* chore: add api to lint:ts

* fix: remove unnecessary typeRoots config
2023-03-22 17:59:46 +05:30
renovate[bot]
607111978a
fix(deps): update prisma monorepo to v4.11.0 (#49758)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2023-03-19 12:25:26 +05:30
Oliver Eyton-Williams
17d7fc0af5
feat(api): use pino-pretty for dev logging (#49713)
feat: use pino-pretty for dev logging
2023-03-16 15:42:01 +00:00
Tom
7aeb4ab76b
feat(api): setup jest in new api (#49709)
* feat(api): setup jest in new api

* feat: sample tests
2023-03-16 20:33:40 +05:30
Oliver Eyton-Williams
c2d149ba85
feat(api): create a demo type provider for typebox (#49536)
* feat: create a demo type provider for typebox

* feat: validate reply + share type

* fix: prettify
2023-03-15 14:21:25 +00:00
Oliver Eyton-Williams
fa7955dc75
feat(api): add prisma as orm (#49413) 2023-03-14 17:29:55 +00:00