Writable options.
Sends a DELETE request to the base url. This is equivalent to calling delete with an empty string.
users.delete()
Sends a DELETE request to the given url.
users.delete('2')
Sends a GET request to the base url. This is equivalent to calling get with an empty string.
const userList = await users.get()
Sends a GET request to the given url.
const userProfile = await users.get('2')
Sends a PATCH request to the base url. This is equivalent to calling patch with an empty string.
users.patch({ name: 'Eduardo' })
Sends a PATCH request to the given url.
users.patch('2', { name: 'Eduardo' })
Sends a POST request to the base url. This is equivalent to calling post with an empty string.
const createdUser = await users.post({ name: 'Eduardo' })
Sends a POST request to the given url.
const createdUser = await users.post('', { name: 'Eduardo' })
Sends a PUT request to the base url. This is equivalent to calling put with an empty string.
users.put({ name: 'Eduardo' })
Sends a PUT request to the given url.
users.put('2', { name: 'Eduardo' })
Object returned by mande