Skip to content
This repository has been archived by the owner on Apr 19, 2023. It is now read-only.

Commit

Permalink
✨ Add API versioning
Browse files Browse the repository at this point in the history
  • Loading branch information
AnandChowdhary committed Jul 24, 2019
1 parent cbc8089 commit 50dfbc7
Show file tree
Hide file tree
Showing 6 changed files with 7 additions and 7 deletions.
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "staart-manager",
"version": "1.0.104",
"version": "1.0.105",
"main": "index.js",
"repository": "[email protected]:AnandChowdhary/staart.git",
"author": "Anand Chowdhary <[email protected]>",
Expand Down Expand Up @@ -135,5 +135,5 @@
"setup"
],
"snyk": true,
"staart-version": "1.0.104"
"staart-version": "1.0.105"
}
2 changes: 1 addition & 1 deletion src/controllers/v1/admin.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ import {
import { authHandler } from "../../helpers/middleware";
import asyncHandler from "express-async-handler";

@Controller("admin")
@Controller("v1/admin")
@ClassMiddleware(authHandler)
@ClassWrapper(asyncHandler)
export class AdminController {
Expand Down
2 changes: 1 addition & 1 deletion src/controllers/v1/auth.ts
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ const OAuthRedirect = (
);
};

@Controller("auth")
@Controller("v1/auth")
@ClassMiddleware(bruteForceHandler)
@ClassWrapper(asyncHandler)
export class AuthController {
Expand Down
2 changes: 1 addition & 1 deletion src/controllers/v1/membership.ts
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ import Joi from "@hapi/joi";
import { joiValidate } from "../../helpers/utils";
import i18n from "../../i18n";

@Controller("memberships")
@Controller("v1/memberships")
@ClassWrapper(asyncHandler)
@ClassMiddleware(authHandler)
export class MembershipController {
Expand Down
2 changes: 1 addition & 1 deletion src/controllers/v1/organization.ts
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ import {
} from "../../helpers/utils";
import Joi from "@hapi/joi";

@Controller("organizations")
@Controller("v1/organizations")
@ClassWrapper(asyncHandler)
@ClassMiddleware(authHandler)
export class OrganizationController {
Expand Down
2 changes: 1 addition & 1 deletion src/controllers/v1/user.ts
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ import asyncHandler from "express-async-handler";
import { joiValidate, userUsernameToId } from "../../helpers/utils";
import Joi from "@hapi/joi";

@Controller("users")
@Controller("v1/users")
@ClassMiddleware(authHandler)
@ClassWrapper(asyncHandler)
export class UserController {
Expand Down

0 comments on commit 50dfbc7

Please sign in to comment.