-
-
Notifications
You must be signed in to change notification settings - Fork 286
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Is it possible to get json object decribing all the routes and their respective methods in one of the server hooks? #1160
Labels
Comments
Hello @shivanshtalwar0, import {Platform} from "@tsed/common";
@Configuration()
export class Server {
@Inject()
platform: Platform;
$onReady(){
const routes = this.platform.getRoutes()
}
} You can also build your own json by using platform API (if you want more details). See the swagger service example: See you |
Wow thank you so much! 😄 |
@Romakita is it removed in v7? |
Yes it’s replaced by You can find here how a layer is mapped to display logs:
see you |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Just like info regarding routes and methods are spit out of server when it is started up.
┌────────────────┬──────────────────────────┬───────────────────────────────────┐
│ Method │ Endpoint │ Class method │
│────────────────│──────────────────────────│───────────────────────────────────│
│ GET │ /rest/auth/health │ Auth.healthCheck() │
│────────────────│──────────────────────────│───────────────────────────────────│
│ POST │ /rest/auth/login │ Auth.logIn() │
│────────────────│──────────────────────────│───────────────────────────────────│
│ POST │ /rest/auth/resetPassword │ Auth.resetPassword() │
│────────────────│──────────────────────────│───────────────────────────────────│
│ GET │ /rest/auth/verify/:token │ Auth.verifyAccount() │
│────────────────│──────────────────────────│───────────────────────────────────│
│ POST │ /rest/auth/register │ Auth.register() │
│────────────────│──────────────────────────│───────────────────────────────────│
│ POST │ /rest/auth/google │ Auth.googleAuth() │
│────────────────│──────────────────────────│───────────────────────────────────│
│ GET │ /rest/auth/reset/:token │ Auth.validateResetPasswordToken() │
│────────────────│──────────────────────────│───────────────────────────────────│
│ POST │ /rest/auth/reset/:token │ Auth.applyResetPasswordToken() │
│────────────────│──────────────────────────│───────────────────────────────────│
│ GET │ /rest/rbac/role │ Auth.getRoles() │
│────────────────│──────────────────────────│───────────────────────────────────│
│ POST │ /rest/rbac/role │ Auth.createRoles()
The text was updated successfully, but these errors were encountered: