HEX
Server: nginx/1.24.0
System: Linux nowruzgan 6.8.0-57-generic #59-Ubuntu SMP PREEMPT_DYNAMIC Sat Mar 15 17:40:59 UTC 2025 x86_64
User: babak (1000)
PHP: 8.3.6
Disabled: NONE
Upload Files
File: /var/dev/irantv2.com/rest/config/routes.js
/**
 * Route Mappings
 * (sails.config.routes)
 *
 * Your routes tell Sails what to do each time it receives a request.
 *
 * For more information on configuring custom routes, check out:
 * https://sailsjs.com/anatomy/config/routes-js
 */

module.exports.routes = {


  //  ╦ ╦╔═╗╔╗ ╔═╗╔═╗╔═╗╔═╗╔═╗
  //  ║║║║╣ ╠╩╗╠═╝╠═╣║ ╦║╣ ╚═╗
  //  ╚╩╝╚═╝╚═╝╩  ╩ ╩╚═╝╚═╝╚═╝

  /***************************************************************************
  *                                                                          *
  * Make the view located at `views/homepage.ejs` your home page.            *
  *                                                                          *
  * (Alternatively, remove this and add an `index.html` file in your         *
  * `assets` directory)                                                      *
  *                                                                          *
  ***************************************************************************/

  '/': {
    view: 'pages/homepage'
  },

  /***************************************************************************
  *                                                                          *
  * More custom routes here...                                               *
  * (See https://sailsjs.com/config/routes for examples.)                    *
  *                                                                          *
  * If a request to a URL doesn't match any of the routes in this file, it   *
  * is matched against "shadow routes" (e.g. blueprint routes).  If it does  *
  * not match any of those, it is matched against static assets.             *
  *                                                                          *
  ***************************************************************************/

  'GET /api/v1.0/file/:fileid': {
    controller: 'FileController',
    action: 'load',
    skipAssets: false
  },
  'GET /api/v1.0/file/:fileid/:filename': {
    controller: 'FileController',
    action: 'load',
    skipAssets: false
  },
  'DELETE /api/v1.0/file/:fileid': {
    controller: 'FileController',
    action: 'remove',
    skipAssets: false
  },
  'POST /api/v1.0/file': 'FileController.create',
  
  'GET /api/v1.0/verify/:phone': 'VerifyController.send',
  'GET /api/v1.0/verify/:phone/:code': 'VerifyController.check',

  'GET /api/v1.0/user/me': {action: 'user/find-me'},
  'PATCH /api/v1.0/user/me': {action: 'user/save-me'},

  // 'GET /api/v1.0/search-admin/stats': {action: 'search-admin/stats'},
  // 'GET /api/v1.0/search-admin/clear': {action: 'search-admin/clear'},
  // 'GET /api/v1.0/search-admin/index/:docType/:offset/:size': {action: 'search-admin/index'},

  'GET /api/v1.0/search/:query':  {action: 'search/search'},

  'GET /api/v1.0/option/:key': {action: 'option/find-one'},
  'PATCH /api/v1.0/option/:key': {action: 'option/update'},

  'GET /api/v1.0/episode/:id/places': {action: 'episode/find-places'},
  'PATCH /api/v1.0/episode/:id/places': {action: 'episode/update-places'},
  'GET /api/v1.0/episode/:id/persons': {action: 'episode/find-persons'},
  'PATCH /api/v1.0/episode/:id/persons': {action: 'episode/update-persons'},
  'GET /api/v1.0/episode/:id/books': {action: 'episode/find-books'},
  'PATCH /api/v1.0/episode/:id/books': {action: 'episode/update-books'},

  'GET /api/v1.0/person/:id/places': {action: 'person/find-places'},
  'PATCH /api/v1.0/person/:id/places': {action: 'person/update-places'},

  'GET /api/v1.0/book/:id/persons': {action: 'book/find-persons'},
  'PATCH /api/v1.0/book/:id/persons': {action: 'book/update-persons'},

  'GET /api/v1.0/article/:id/authors': {action: 'article/find-authors'},
  'PATCH /api/v1.0/article/:id/authors': {action: 'article/update-authors'},
  // 'GET /api/v1.0/article/:id/persons': {action: 'article/find-persons'},
  // 'PATCH /api/v1.0/article/:id/persons': {action: 'article/update-persons'},
  // 'GET /api/v1.0/article/:id/books': {action: 'article/find-books'},
  // 'PATCH /api/v1.0/article/:id/books': {action: 'article/update-books'},
  // 'GET /api/v1.0/article/:id/places': {action: 'article/find-places'},
  // 'PATCH /api/v1.0/article/:id/places': {action: 'article/update-places'},
  
  'GET /api/v1.0/endpoint': 'EndpointController.data',
};