Remove a user from a Team
DELETE
/api/v2/account_invites
const url = 'https://api.payhero.africa/api/v2/account_invites?account_id=63&user_id=42';const options = {method: 'DELETE', headers: {Authorization: 'Basic <credentials>'}};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request DELETE \ --url 'https://api.payhero.africa/api/v2/account_invites?account_id=63&user_id=42' \ --header 'Authorization: Basic <credentials>'Removes a user from a Team. Identify both via query parameters.
Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Query Parameters
Section titled “Query Parameters”account_id
required
integer
Example
63user_id
required
integer
Example
42Responses
Section titled “Responses”The user was removed from the Team.
Media typeapplication/json
object
account_id
integer
user_id
integer
Example
{ "account_id": 63, "user_id": 42}Missing or invalid Basic auth credentials.
Media typeapplication/json
object
error_code
string
error_message
string
status_code
integer
Example
{ "error_code": "invalid_argument", "error_message": "the transaction amount is insufficient as it wont cater for cost: (4.62)", "status_code": 400}
