I am trying to load some test data. I have created a master API key with userId = 1. Then I create a discussion and post to it using user id's 1 and 3:
[2021-06-01 14:22:29] flarum.DEBUG: {
"json": {
"data": {
"attributes": {
"content": "Our Hero!"
},
"relationships": {
"discussion": {
"data": {
"id": 15,
"type": "discussions"
}
}
}
}
},
"headers": {
"Authorization": "Token <my token>;userId=1"
}
}
[2021-06-01 14:22:29] flarum.DEBUG: ApiClient::request: options = ...
[2021-06-01 14:22:29] flarum.DEBUG: {
"json": {
"data": {
"attributes": {
"content": "Yes! whenever bicycles are broken, or menaced by international communism, Bicycle Repair Man is ready!"
},
"relationships": {
"discussion": {
"data": {
"id": 15,
"type": "discussions"
}
}
}
}
},
"headers": {
"Authorization": "Token <my token>;userId=3"
}
}
The discussion gets created and the posts get posted, but they all show userId=1 as the poster. I thought they would get posted as the userId in the authentication header. How do I accomplish this?
Thanks,
Bob