Addressbook
Function-calling namespace: addressbook
- Base URL:
https://api.aivida.in - Engine endpoint:
POST /api - Auth: Stack token middleware enabled in
optionalmode. - Send token in header:
x-stack-access-token: <access_token>(orAuthorization: Bearer <access_token>). - In
optionalmode: no token is allowed; invalid token is rejected with401.
create
Source: backend/endpoints/addressbook/create
Input Fields
| Field | Type | Required |
|---|---|---|
userId | string | Yes |
addressType | string | Yes |
address | string | Yes |
city | string | Yes |
state | string | Yes |
country | string | Yes |
postcode | string | Yes |
Example Request
curl -X POST https://api.aivida.in/api \
-H "Content-Type: application/json" \
-H "x-stack-access-token: <access_token_optional>" \
-d '{
"namespace": "addressbook",
"apiName": "create",
"data": {
"userId": "user_123",
"addressType": "GENERAL",
"address": "value",
"city": "value",
"state": "value",
"country": "value",
"postcode": "value"
}
}'Example Response
{ "status": "ok", "data": {} }getActiveByUserId
Source: backend/endpoints/addressbook/get-active-by-user-id
Input Fields
| Field | Type | Required |
|---|---|---|
userId | string | Yes |
Example Request
curl -X POST https://api.aivida.in/api \
-H "Content-Type: application/json" \
-H "x-stack-access-token: <access_token_optional>" \
-d '{
"namespace": "addressbook",
"apiName": "getActiveByUserId",
"data": {
"userId": "user_123"
}
}'Example Response
{ "status": "ok", "data": {} }getById
Source: backend/endpoints/addressbook/get-by-id
Input Fields
| Field | Type | Required |
|---|---|---|
id | string | Yes |
Example Request
curl -X POST https://api.aivida.in/api \
-H "Content-Type: application/json" \
-H "x-stack-access-token: <access_token_optional>" \
-d '{
"namespace": "addressbook",
"apiName": "getById",
"data": {
"id": "id_123"
}
}'Example Response
{ "status": "ok", "data": {} }getByUserId
Source: backend/endpoints/addressbook/get-by-user-id
Input Fields
| Field | Type | Required |
|---|---|---|
userId | string | Yes |
Example Request
curl -X POST https://api.aivida.in/api \
-H "Content-Type: application/json" \
-H "x-stack-access-token: <access_token_optional>" \
-d '{
"namespace": "addressbook",
"apiName": "getByUserId",
"data": {
"userId": "user_123"
}
}'Example Response
{ "status": "ok", "data": {} }softDelete
Source: backend/endpoints/addressbook/soft-delete
Input Fields
| Field | Type | Required |
|---|---|---|
id | string | Yes |
Example Request
curl -X POST https://api.aivida.in/api \
-H "Content-Type: application/json" \
-H "x-stack-access-token: <access_token_optional>" \
-d '{
"namespace": "addressbook",
"apiName": "softDelete",
"data": {
"id": "id_123"
}
}'Example Response
{ "status": "ok", "data": {} }update
Source: backend/endpoints/addressbook/update
Input Fields
| Field | Type | Required |
|---|---|---|
id | string | Yes |
addressType | *string | No |
address | *string | No |
city | *string | No |
state | *string | No |
country | *string | No |
postcode | *string | No |
isActive | *bool | No |
Example Request
curl -X POST https://api.aivida.in/api \
-H "Content-Type: application/json" \
-H "x-stack-access-token: <access_token_optional>" \
-d '{
"namespace": "addressbook",
"apiName": "update",
"data": {
"id": "id_123"
}
}'Example Response
{ "status": "ok", "data": {} }