如何在 POSTMAN 中将 YML 作为请求正文发送
How to send YML as request body in POSTMAN
我有一个 YML 文件:
{language: en, pipeline: null, policies: null}
version: '2.0'
intents: [greet, goodbye, affirm, deny, mood_great, mood_unhappy, bot_challenge]
responses:
utter_greet:
- {text: 'Hey! How are you?'}
utter_cheer_up:
- {text: 'Here is something to cheer you up:', image: 'https://i.imgur.com/nGF1K8f.jpg'}
utter_did_that_help:
- {text: 'Did that help you?'}
utter_happy:
- {text: 'Great, carry on!'}
utter_goodbye:
- {text: Bye}
utter_iamabot:
- {text: 'I am a bot, powered by Rasa.'}
session_config: {session_expiration_time: 60, carry_over_slots_to_new_session: true}
现在如何使用 POSTMAN 发送 POST 请求...
我需要发送一个 POST 请求,但是在 POSTMAN 中我无法将 requestbody 类型设置为 x-yaml.?
https://www.getpostman.com/collections/43deac65a6de60ac46b3
一个示例集合只需单击导入>在邮递员中使用link并粘贴它
所以您需要做的是将正文设置为文本,将内容类型设置为 application/x-yaml
YAML media type?
我有一个 YML 文件:
{language: en, pipeline: null, policies: null}
version: '2.0'
intents: [greet, goodbye, affirm, deny, mood_great, mood_unhappy, bot_challenge]
responses:
utter_greet:
- {text: 'Hey! How are you?'}
utter_cheer_up:
- {text: 'Here is something to cheer you up:', image: 'https://i.imgur.com/nGF1K8f.jpg'}
utter_did_that_help:
- {text: 'Did that help you?'}
utter_happy:
- {text: 'Great, carry on!'}
utter_goodbye:
- {text: Bye}
utter_iamabot:
- {text: 'I am a bot, powered by Rasa.'}
session_config: {session_expiration_time: 60, carry_over_slots_to_new_session: true}
现在如何使用 POSTMAN 发送 POST 请求... 我需要发送一个 POST 请求,但是在 POSTMAN 中我无法将 requestbody 类型设置为 x-yaml.?
https://www.getpostman.com/collections/43deac65a6de60ac46b3
一个示例集合只需单击导入>在邮递员中使用link并粘贴它
所以您需要做的是将正文设置为文本,将内容类型设置为 application/x-yaml
YAML media type?