gcliff
(CLIFF GITA)
November 17, 2019, 7:05am
1
Hello devs;
I am trying to create an order to be used in this issue with this
url http://localhost:8081/openmrs-standalone/ws/rest/v1/order
JSON body content with valid UUIDs: https://pastebin.com/R7RP69Gh
but am getting this error https://pastebin.com/KuqzzXQi
I have followed the solution proposed by @darius in this thread but no break through, still getting the same error .
kindly requesting for your help
@mogoodrich @ruhanga @mozzy @mksd
ruhanga
(Nathan Ruhanga)
November 18, 2019, 8:35am
3
@gcliff , have you tried this on demo server ?
ruhanga
(Nathan Ruhanga)
November 18, 2019, 8:50am
4
You may also want to validate the JSON content you are posting. The logs show you might have posted JSON content with "type" : "orderorder"
where as the JSON snippet you shared indicates "type" : "testorder"
gcliff
(CLIFF GITA)
November 18, 2019, 8:51am
5
demo server sims to be abit down but am going to try it out
gcliff
(CLIFF GITA)
November 18, 2019, 9:11am
6
yes @ruhanga but i still get this error with this JSON content
ruhanga
(Nathan Ruhanga)
November 18, 2019, 9:25am
7
@gcliff , also ensure the orderType
attribute is not an array, but rather a single uuid, probably the one the matches the Test-Order order type as per your use case.
ruhanga
(Nathan Ruhanga)
November 18, 2019, 9:39am
8
ruhanga:
orderType
I’m not sure whether you need this attribute at all though. Most probably not.
gcliff
(CLIFF GITA)
November 18, 2019, 9:41am
9
i tried that before n separated the the uuids of the order types but still got the same feedback
gcliff
(CLIFF GITA)
November 18, 2019, 9:42am
10
order type is required in order to create an Order according to the swagger specs
ruhanga
(Nathan Ruhanga)
November 18, 2019, 9:47am
11
Could you share a snippet of what you attempted and the feedback you got?
gcliff
(CLIFF GITA)
November 18, 2019, 4:54pm
12
https://pastebin.com/9SsqVYya am required to create an encounter first coz its missing in order for the test, gonna work on it
Thanks @ruhanga
burke
(Burke Mamlin)
November 18, 2019, 6:41pm
13
@batbrain7 & @ayesh ,
Ideally, our REST documentation at rest.openmrs.org should be answering questions like you see above.
4 Likes
ayesh
(Ayeshmantha Perera)
November 18, 2019, 7:26pm
14
Yes.I think we have already covered order type in docs @burke
1 Like
tendomart
(tendo kiiza Martyn)
November 19, 2019, 5:21am
15
Iam very eager to see the User experience from this new Documentation.
burke
(Burke Mamlin)
November 19, 2019, 2:30pm
16
Try it out and share your feedback here .
We have a start, but I’d be curious if the current documentation is helpful to those who need it. For example, I don’t believe the example we have for posting an order works.
ayesh
(Ayeshmantha Perera)
November 19, 2019, 3:26pm
17
@batbrain7
I think the creation of resources which we show case should work in examples.Will it be possible to double check
thanks