• Method decorator that indicates the method should be accessible through an HTTP Put operation

    Example

    @Controller('/api', 'User', 'User Management Routes')
    class User {

    @HttpPut('/user/:userId', 'Update an existing user')
    async createUser(
    @UrlParam('userId') userId: number,
    @RequestParam('password') password: string,
    @Response() res: ExpressResponse
    ): Promise<void> {
    ...
    }
    }

    Type Parameters

    • T

      Class method to be registered with the Express application as a put route

    Parameters

    • path: string

      URL which this method should be access through as a HTTP Put operation

    • Optional description: string

      Description of this route to be included in the OpenAPI documentation

    Returns ((target: T, propertyKey: string) => void)

      • (target: T, propertyKey: string): void
      • Parameters

        • target: T
        • propertyKey: string

        Returns void

Generated using TypeDoc