Pular para o conteúdo principal

Inventário de Endpoints REST

Fonte principal: we-dhedalos/functions/rest/**.

Convenção de URL

  • Prefixo customizado de REST: /api (filtro rest_url_prefix em we-dhedalos/functions/wp/rest_path.php).
  • Exemplo final: /api/dhedalos/v1/search.

Matriz de rotas

EndpointMétodosPermissão principalArquivo
/dhedalos/v1/searchGET__return_truewe-dhedalos/functions/rest/search_summary.php
/dhedalos/v1/theme_settingsGET__return_truewe-dhedalos/functions/rest/theme_settings.php
/dhedalos/v1/maintenance_modeGET__return_truewe-dhedalos/functions/rest/maintenance_mode.php
/dhedalos/v1/userGET, POSTis_user_logged_inwe-dhedalos/functions/rest/user.php
/dhedalos/v1/login_by_cpfGET, POSTis_user_logged_inwe-dhedalos/functions/rest/login_by_cpf.php
/dhedalos/v1/user_by_cpfGETis_user_logged_inwe-dhedalos/functions/rest/login_by_cpf.php
/dhedalos/v1/registration/peoplePOSTrest_auth_validate_tokenwe-dhedalos/functions/rest/registration/signup.php
/dhedalos/v1/registration/people/{cpf}GETrest_auth_validate_tokenwe-dhedalos/functions/rest/registration/find.php
/dhedalos/v1/registration/people/phone/{phone}GETrest_auth_validate_tokenwe-dhedalos/functions/rest/registration/findbyphone.php
/dhedalos/v1/registration/people/{id}PUTrest_auth_validate_tokenwe-dhedalos/functions/rest/registration/update_put.php
/dhedalos/v1/registration/people/{id}PATCHrest_auth_validate_tokenwe-dhedalos/functions/rest/registration/update_patch.php
/dhedalos/v1/enroll/{slug_curso}/statusGETrest_auth_validate_tokenwe-dhedalos/functions/rest/course/enroll_open.php
/dhedalos/v1/enroll/{slug_curso}/metaPOSTrest_auth_validate_tokenwe-dhedalos/functions/rest/course/enroll_meta.php
/dhedalos/v1/enroll/{slug_curso}POSTrest_auth_validate_tokenwe-dhedalos/functions/rest/course/enroll.php
/dhedalos/v1/enroll/cancel/{enrollment_id}POSTis_user_logged_inwe-dhedalos/functions/rest/course/enroll.php
/dhedalos/v1/enroll/{enroll_id}DELETErest_auth_validate_tokenwe-dhedalos/functions/rest/course/disenroll.php
/dhedalos/v1/course/enrolled/{slug_curso}/{user_id}GETrest_auth_validate_tokenwe-dhedalos/functions/rest/course/enrolled.php
/dhedalos/v1/group/{uid}GETrest_auth_validate_tokenwe-dhedalos/functions/rest/course/group_link.php
/dhedalos/v1/group/recall_group_linkGETrest_auth_validate_tokenwe-dhedalos/functions/rest/course/inactive_group.php
/dhedalos/v1/coursesGETcallback local (usuário logado + role)we-dhedalos/functions/rest/courses.php
/dhedalos/v1/courses/sidebarGETcallback local (usuário logado + role)we-dhedalos/functions/rest/courses.php
/dhedalos/v1/course/{slug}GETsem permission_callback explicitowe-dhedalos/functions/rest/courses.php
/dhedalos/v1/courses/{class_id}/meeting-typeGETcallback local (usuário logado + role)we-dhedalos/functions/rest/courses.php
/dhedalos/v1/course/{slug}/next-cycleGETsem permission_callback explicitowe-dhedalos/functions/rest/courses.php
/dhedalos/v1/cyclesGETcallback local (usuário logado + role)we-dhedalos/functions/rest/cycles.php
/dhedalos/v1/cycles/{cycle_id}/classesGETcallback local (usuário logado + role)we-dhedalos/functions/rest/cycles.php
/dhedalos/v1/cycles/{year}GETcallback local (usuário logado + role)we-dhedalos/functions/rest/cycles.php
/dhedalos/v1/cycles/pcd-upcomingGETrest_auth_validate_tokenwe-dhedalos/functions/rest/cycles.php
/dhedalos/v1/cycles/recovery-statusGETcallback local (is_user_logged_in)we-dhedalos/functions/rest/cycles.php
/dhedalos/v1/classes/supervisorGETcallback local (is_user_logged_in + role)we-dhedalos/functions/rest/classes.php
/dhedalos/v1/classes/facilitatorGETcallback local (is_user_logged_in + role)we-dhedalos/functions/rest/classes.php
/dhedalos/v1/classes/subscriberGETcallback local (is_user_logged_in + role)we-dhedalos/functions/rest/classes.php
/dhedalos/v1/class/{class_id}GETcallback local (is_user_logged_in + role)we-dhedalos/functions/rest/classes.php
/dhedalos/v1/class/{class_id}/facilitatorGETcallback local (is_user_logged_in + role)we-dhedalos/functions/rest/classes.php
/dhedalos/v1/classes/subscriber/{subscriber_id}/cpfGETcallback local (is_user_logged_in + role)we-dhedalos/functions/rest/classes.php
/dhedalos/v1/class/{class_id}/presenceGETcallback local (is_user_logged_in + role)we-dhedalos/functions/rest/classes.php
/dhedalos/v1/class/{class_id}/participantsGETcallback local (is_user_logged_in + role)we-dhedalos/functions/rest/classes.php
/dhedalos/v1/class/{class_id}/student/{student_id}/activity/{activity}POSTcallback local (role admin/supervisor/facilitator)we-dhedalos/functions/rest/classes.php
/dhedalos/v1/class/{class_id}/recovery-presence/{activity}POSTcallback local (is_user_logged_in + roles_allowed)we-dhedalos/functions/rest/classes.php
/dhedalos/v1/class/{class_id}/auto-presencePOSTcallback local (current_user_can custom)we-dhedalos/functions/rest/classes.php
/dhedalos/v1/user/{subscriber_id}/dataGETrest_auth_validate_tokenwe-dhedalos/functions/rest/classes.php
/dhedalos/v1/enrollment/{enrollment_id}/request-cancellationEDITABLE__return_truewe-dhedalos/functions/rest/classes.php
/dhedalos/v1/facilitator/calendarGETuser_is_facilitatorwe-dhedalos/functions/rest/calendar.php
/dhedalos/v1/facilitator/calendarPOSTuser_is_adminwe-dhedalos/functions/rest/calendar.php
/dhedalos/v1/individual/disponibilityGETis_user_logged_inwe-dhedalos/functions/rest/individual_disponibility.php
/dhedalos/v1/individual/available-slotsGETis_user_logged_inwe-dhedalos/functions/rest/individual_disponibility.php
/dhedalos/v1/individual/bookingPOSTcallback local (is_user_logged_in)we-dhedalos/functions/rest/individual_booking.php
/dhedalos/v1/individual/bookingDELETEcallback local (is_user_logged_in)we-dhedalos/functions/rest/individual_booking.php
/dhedalos/v1/individual/bookingsGETis_user_logged_inwe-dhedalos/functions/rest/my_calendar.php
/dhedalos/v1/bookings/{booking_id}GETis_user_logged_inwe-dhedalos/functions/rest/my_calendar.php
/dhedalos/v1/class_roomGETcallback local (is_user_logged_in)we-dhedalos/functions/rest/class_room.php
/dhedalos/v1/class_room/one_on_oneGETcallback local (is_user_logged_in)we-dhedalos/functions/rest/class_room.php
/dhedalos/v1/class_room/groupGETcallback local (is_user_logged_in)we-dhedalos/functions/rest/class_room.php
/dhedalos/v1/live/cyclesGETrest_auth_validate_tokenwe-dhedalos/functions/rest/live/cycles.php
/dhedalos/v1/live/enrollmentsGETrest_auth_validate_tokenwe-dhedalos/functions/rest/live/enrollments.php
/dhedalos/v1/live/enrollments-statsGETrest_auth_validate_tokenwe-dhedalos/functions/rest/live/enrollments-stats.php
/dhedalos/v1/live/enrolls_by_cycleGETrest_auth_validate_tokenwe-dhedalos/functions/rest/live/enrolls_by_cycle.php
/dhedalos/v1/logsPOSTcallback local (is_user_logged_in)we-dhedalos/functions/rest/logs.php
/dhedalos/v1/participant-mode-logPOSTcallback local (is_user_logged_in)we-dhedalos/functions/rest/participant_mode_logs.php
/dhedalos/v1/system-logsGETrest_auth_validate_tokenwe-dhedalos/functions/rest/system_logs.php
/dhedalos/v1/system-logs/statsGETrest_auth_validate_tokenwe-dhedalos/functions/rest/system_logs.php
/dhedalos/v1/partners/{code}GETrest_auth_validate_tokenwe-dhedalos/functions/rest/partners.php
/dhedalos/v1/surplus/{course_slug}GETrest_auth_validate_tokenwe-dhedalos/functions/rest/relocate_participant.php
/dhedalos/v1/realocatedGETrest_auth_validate_tokenwe-dhedalos/functions/rest/relocate_participant.php
/dhedalos/v1/duplicated-students/searchGETrest_auth_validate_tokenwe-dhedalos/functions/rest/duplicated_students.php
/dhedalos/v1/duplicated-students/deleteGETrest_auth_validate_tokenwe-dhedalos/functions/rest/duplicated_students.php
/dhedalos/v1/testsGETrest_auth_validate_tokenwe-dhedalos/functions/rest/tests.php
/dhedalos/v1/tests/linksGETrest_auth_validate_tokenwe-dhedalos/functions/rest/tests.php
/dhedalos/v1/tests/fixtures/createPOSTrest_auth_validate_tokenwe-dhedalos/functions/rest/tests-fixtures.php
/dhedalos/v1/tests/fixtures/cleanupDELETErest_auth_validate_tokenwe-dhedalos/functions/rest/tests-fixtures.php
/dhedalos/v1/tests/fixtures/linksPOSTrest_auth_validate_tokenwe-dhedalos/functions/rest/tests-fixtures.php
/dhedalos/v1/export/usersGETcurrent_user_can('manage_options')we-dhedalos/functions/rest/export.php
/dhedalos/v1/export/classesGETcurrent_user_can('manage_options')we-dhedalos/functions/rest/export.php
/dhedalos/v1/export/coursesGETrest_auth_validate_tokenwe-dhedalos/functions/rest/export.php
/dhedalos/v1/export/enrollmentsGETrest_auth_validate_tokenwe-dhedalos/functions/rest/export.php
/dhedalos/v1/export/activitiesGETcurrent_user_can('manage_options')we-dhedalos/functions/rest/export.php
/dhedalos/v1/export/enrollment-statsGETrest_auth_validate_tokenwe-dhedalos/functions/rest/export.php
/dhedalos/v1/export/cycles-statsGETrest_auth_validate_tokenwe-dhedalos/functions/rest/export.php

Pendências

  • WP_REST_Server::EDITABLE não detalha método HTTP único no inventário; a implementação aceita métodos editáveis do WP REST.
  • Há rotas com permission_callback inline que dependem de combinação de is_user_logged_in, role e validações de negócio no callback.
  • A rota DELETE /dhedalos/v1/enroll/{enroll_id} é condicionada por ambiente (piloto/homolog) no próprio registro da rota.
  • A rota /dhedalos/v1/cycles/recovery-status registra o parâmetro class_idd (com dois d) no estado atual do código.