I'm trying to use RESTool with an API that, when creating a new user, requires a PUT request with the new user name in the URL.
Now if I define
"post": {
"actualMethod": "put",
"url": "/users/:username",
"fields": [
{
"name": "username",
"type": "text",
"label": "User name"
},
{
"name": "password",
"type": "text",
"label": "Password"
}
]
}
the server returns an error because the field is not expected in the body. However, if I don't define it in "fields", the UI will not generate a corresponding input field.
A possible solution would be exclude the field from the body if it is already part of the url.
Perhaps there is a solution with custom fields, but if so, I don't know how to use them for an "Add Item" functionality.
I'm trying to use RESTool with an API that, when creating a new user, requires a PUT request with the new user name in the URL.
Now if I define
the server returns an error because the field is not expected in the body. However, if I don't define it in "fields", the UI will not generate a corresponding input field.
A possible solution would be exclude the field from the body if it is already part of the url.
Perhaps there is a solution with custom fields, but if so, I don't know how to use them for an "Add Item" functionality.