【发布时间】:2020-06-08 15:11:36
【问题描述】:
我正在尝试在 Jmeter 中获取访问令牌,它与邮递员一起工作正常,但我最终在 Jmeter 中响应错误提示
{
"error":"invalid_grant",
"error_description":"The provided authorization grant (e.g., authorization code, resource owner credentials) or refresh token is invalid, expired, revoked, does not match the redirection URI used in the authorization request, or was issued to another client",
"status_code":400
}
邮递员身体
邮递员中的标题
当我发布此请求时,我得到了访问令牌作为 json 响应
我在 Jmeter 中的设置如下:
HTTP 请求
HTTP 标头
当我在 jmeter 中运行测试时得到以下响应
{
"error":"invalid_grant",
"error_description":"The provided authorization grant (e.g., authorization code, resource owner credentials) or refresh token is invalid, expired, revoked, does not match the redirection URI used in the authorization request, or was issued to another client",
"status_code":400
}
【问题讨论】:
-
请提供jmeter日志。要获取或提取访问令牌,您应该使用 Json 提取器或 xpath 提取器。
标签: rest api oauth jmeter performance-testing