Login Redirect Entry Points
This document provides entry points for redirecting to or embedding WeSurvey.
Note:
- This is not a backend request API, it's only used as an entry point for users to directly access or third-party login to the survey;
- Please
avoid
directly concatenating page URLs likehttps://wesurvey.com/edit.html?tid=30
for embedding, to prevent link failure due to WeSurvey modifications.- This API does not require access_token
Redirect with Third-party Login State
Guide users to click or directly HTTP 302 redirect to the following link:
https://wesurvey.com/api/v2/redirect?appid={appid}&code={code}&action={action}
Note: The API will redirect to corresponding pages based on different actions, code comes from Get One-time Login Code.
- Survey Editor View
action | Function | Other Required Parameters | Example |
---|---|---|---|
my_surveys | Personal Survey List | https://wesurvey.com/api/v2/redirect?action=my_surveys | |
org_surveys | Team Survey List | org_id (Team ID) | https://wesurvey.com/api/v2/redirect?action=org_surveys&org_id=60000208206 |
survey_create | Create Personal Survey | https://wesurvey.com/api/v2/redirect?action=survey_create | |
org_survey_create | Create Team Survey | org_id (Team ID) | https://wesurvey.com/api/v2/redirect?action=org_survey_create&org_id=60000208206 |
org_survey_create_in_project | Create Team Survey in Project | org_id (Team ID) project_id (Project ID) Can be obtained from Shared Project List API | https://wesurvey.com/api/v2/redirect?action=org_survey_create_in_project&org_id=60000208206&project_id=391504 |
survey_edit | Edit Survey | survey_id (Survey ID) | https://wesurvey.com/api/v2/redirect?action=survey_edit&survey_id=8068279 |
survey_setting | Survey Settings | survey_id (Survey ID) | |
survey_overview | Statistics Results | survey_id (Survey ID) | |
survey_print | Print Survey | survey_id (Survey ID) | |
survey_skin | Survey Theme | survey_id (Survey ID) | |
survey_dsl | Custom Logic Editor | survey_id (Survey ID) | |
org_info | Team Information | org_id (Team ID) | |
org_contacts | Team Contacts | org_id (Team ID) | |
answer_detail | Response Detail | survey_id (Survey ID) answer_id (Response ID) | https://wesurvey.com/api/v2/redirect?action=answer_detail&survey_id=8068279&answer_id=1 |
exam_survey_create | Create Personal Exam Survey | https://wesurvey.com/api/v2/redirect?action=exam_survey_create | |
org_exam_survey_create | Create Team Exam Survey | org_id (Team ID) | https://wesurvey.com/api/v2/redirect?action=org_exam_survey_create&org_id=60000208206 |
exam_survey_overview | Exam Grading | survey_id (Survey ID) | |
exam_survey_answers | Exam Response Data | survey_id (Survey ID) | |
ai_survey_create | Create AI Survey | org_id (Team ID) | https://wesurvey.com/api/v2/redirect?action=ai_survey_create&org_id=60000208206 |
ai_survey_create_in_project | Create AI Survey in Project | org_id (Team ID) project_id (Project ID) Can be obtained from Shared Project List API | https://wesurvey.com/api/v2/redirect?action=ai_survey_create_in_project&org_id=60000208206&project_id=391504 |
- Survey Respondent View
action | Function | Other Required Parameters | Example |
---|---|---|---|
survey_collect | Survey Response Page | survey_id (Survey ID), survey_hash (Survey Hash) | https://wesurvey.com/api/v2/redirect?action=survey_collect&survey_id=8068279&survey_hash=0418 |
Direct Redirect
After performing one of the above Redirect with Third-party Login State
, the browser has set the login state. Subsequent redirects can omit the code
parameter, avoiding the need to Get One-time Login Code for each page.