how can I specify the return type of the response of API response

For example I want to do something like this
type a = (c:any) => JSON<{message: string}>
c.get('/', (): a => {})
Was this page helpful?