3.1 KiB
3.1 KiB
name, title, description
| name | title | description |
|---|---|---|
| formbricks-customer-survey | Formbricks Customer Information Collection Survey Creation | Skill for creating customer information collection surveys in Formbricks using Management API with specific field requirements. |
Overview
Skill for creating customer information collection surveys in Formbricks using Management API with specific field requirements.
Required Fields
- 姓名(必填)
- 公司名称(必填)
- 电子邮箱(必填)
- 手机号码(必填)
- 备注(可选)
API Configuration
- Base URL: https://form.140103.xyz
- API Key: 33513637d4161852807df0eeb734da61
- environmentId: cmlw3055s0008xh6f9aod3sko
- Authentication: x-api-key header
Common Issues & Solutions
1. API Format Errors
Problem: "Fields are missing or incorrectly formatted" errors, especially with endings format Solution: Use the correct endings structure with proper language codes and question IDs
2. Login Issues
Problem: Browser login failures with pre-configured credentials Solution: Use API authentication instead of browser login when possible
3. Questions Array Format
Problem: Questions array structure not accepted Solution: Follow Formbricks API specification for question objects with proper field types
API Endpoint
POST /api/v1/management/surveys
Authentication Header
x-api-key: 33513637d4161852807df0eeb734da61
Survey Payload Structure
{
"name": "客户信息收集问卷",
"description": "用于收集客户基本信息的问卷",
"environmentId": "cmlw3055s0008xh6f9aod3sko",
"published": true,
"endings": {
"zh": {
"thankYou": "感谢您的填写!",
"nextSurveyId": null
}
},
"questions": [
{
"id": "name",
"type": "short_text",
"label": {
"zh": "姓名"
},
"required": true
},
{
"id": "company",
"type": "short_text",
"label": {
"zh": "公司名称"
},
"required": true
},
{
"id": "email",
"type": "email",
"label": {
"zh": "电子邮箱"
},
"required": true
},
{
"id": "phone",
"type": "tel",
"label": {
"zh": "手机号码"
},
"required": true
},
{
"id": "remarks",
"type": "long_text",
"label": {
"zh": "备注"
},
"required": false
}
]
}
Troubleshooting Steps
- If API returns format errors, verify endings structure matches the above example
- Ensure all required fields are included with correct types
- Use proper language codes (zh for Chinese)
- Check API key and environmentId are correct
- If browser login fails, use API authentication instead
Verification
After creation, verify survey exists by:
- Using GET /api/v1/management/surveys to list surveys
- Checking the survey appears in the list
- Retrieving the survey details to confirm all questions are present
Notes
- The survey will be created in the production environment
- The share link can be obtained from the survey details after creation
- If issues persist, check Formbricks API documentation for latest format requirements