如何实现一个API休息在Matlab

54视图(30天)
我能够实现一个API使用webread如下
api = ' https://api.pontomais.com.br/external_api/v1/teams?attributes=id、代码、名称、部门领袖”;
选择= weboptions (“KeyName”、“访问令牌”,“KeyValue”,“XXXXXX”);
Data = webread (api、期权);
但是我不知道如何在Matlab中实现一个帖子。看到下一个旋度的帖子。有人知道怎么做吗?
旋度,位置 - - - 请求 帖子 “https://api.pontomais.com.br/external_api/v1/reports/work_days” \
- - - “application / json内容类型: \
- - - “访问令牌:XXXXXX” \
- - - 数据 - - - - - - 生的 {
“报告” : {
“start_date” : “2021-06-01” ,
“end_date” : “2021-07-01” ,
“group_by” : “员工” ,
“row_filters” : “with_inactives has_time_cards” ,
“列” : “日期、shift_name time_breaks shift_appointments time_cards,总结,extra_time, total_time, shift_time, custom_interval_time, overnight_time, registration_number, time_balance,动机,employee_id” ,
“格式” : “json”
}
}

接受的答案

肖恩·德Wolski
肖恩·德Wolski 2021年8月27日
看:
weboptions (“RequestMethod”,“职位”)
ans =
weboptions属性:CharacterEncoding:‘汽车’UserAgent:“MATLAB 9.10.0.1716447 (R2021a)更新4 '超时:5用户名:密码:“KeyName: KeyValue:“ContentType:“汽车”ContentReader: [] MediaType:“汽车”RequestMethod:“post”ArrayFormat:“csv”HeaderFields: [] CertificateFilename:“违约”
医生webwrite

更多的答案(0)

s manbetx 845

社区寻宝

找到宝藏在MATLAB中央,发现社区如何帮助你!

开始狩猎!