EndpointsDoctor Wallet Transactions

Doctor Wallet Transactions

Function-calling namespace: doctorWalletTransactions

  • Base URL: https://api.aivida.in
  • Engine endpoint: POST /api
  • Auth: Stack token middleware enabled in optional mode.
  • Send token in header: x-stack-access-token: <access_token> (or Authorization: Bearer <access_token>).
  • In optional mode: no token is allowed; invalid token is rejected with 401.

create

Source: backend/endpoints/doctor-wallet-transactions/create

Input Fields

FieldTypeRequiredConstraints
organizationIdstringYes-
doctorIdstringYes-
stackUserIdstringYes-
typestringYes-
amountnumberYes-
descriptionstringYes-
statusstringNo-
appointmentIdstringNo-
consultationIdstringNo-
patientIdstringNo-
withdrawalMethodstringNo-
withdrawalDetailsstringNo-

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": "doctorWalletTransactions",
  "apiName": "create",
  "data": {
    "organizationId": "org_123",
    "doctorId": "doctor_123",
    "stackUserId": "stackuser_123",
    "type": "general",
    "amount": 1,
    "description": "value"
  }
}'

Example Response

{ "status": "ok", "data": {} }

delete

Source: backend/endpoints/doctor-wallet-transactions/delete

Input Fields

FieldTypeRequiredConstraints
idstringYes-
organizationIdstringYes-

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": "doctorWalletTransactions",
  "apiName": "delete",
  "data": {
    "id": "id_123",
    "organizationId": "org_123"
  }
}'

Example Response

{ "status": "ok", "data": {} }

getById

Source: backend/endpoints/doctor-wallet-transactions/get-by-id

Input Fields

FieldTypeRequiredConstraints
idstringYes-
organizationIdstringYes-

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": "doctorWalletTransactions",
  "apiName": "getById",
  "data": {
    "id": "id_123",
    "organizationId": "org_123"
  }
}'

Example Response

{ "status": "ok", "data": {} }

getStats

Source: backend/endpoints/doctor-wallet-transactions/get-stats

Input Fields

FieldTypeRequiredConstraints
organizationIdstringYes-
doctorIdstringYes-

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": "doctorWalletTransactions",
  "apiName": "getStats",
  "data": {
    "organizationId": "org_123",
    "doctorId": "doctor_123"
  }
}'

Example Response

{ "status": "ok", "data": {} }

listByDoctorId

Source: backend/endpoints/doctor-wallet-transactions/list-by-doctor-id

Input Fields

FieldTypeRequiredConstraints
organizationIdstringYes-
doctorIdstringYes-
pageintegerNo-
pageSizeintegerNo-
datestringNoformat: YYYY-MM-DD

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": "doctorWalletTransactions",
  "apiName": "listByDoctorId",
  "data": {
    "organizationId": "org_123",
    "doctorId": "doctor_123"
  }
}'

Example Response

{ "status": "ok", "data": {} }

listByOrganization

Source: backend/endpoints/doctor-wallet-transactions/list-by-organization

Input Fields

FieldTypeRequiredConstraints
organizationIdstringYes-
pageintegerNo-
pageSizeintegerNo-

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": "doctorWalletTransactions",
  "apiName": "listByOrganization",
  "data": {
    "organizationId": "org_123"
  }
}'

Example Response

{ "status": "ok", "data": {} }

requestWithdrawal

Source: backend/endpoints/doctor-wallet-transactions/request-withdrawal

Input Fields

FieldTypeRequiredConstraints
organizationIdstringYes-
doctorIdstringYes-
stackUserIdstringYes-
amountnumberYes-
withdrawalMethodstringYes-
withdrawalDetailsstringNo-

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": "doctorWalletTransactions",
  "apiName": "requestWithdrawal",
  "data": {
    "organizationId": "org_123",
    "doctorId": "doctor_123",
    "stackUserId": "stackuser_123",
    "amount": 1,
    "withdrawalMethod": "value"
  }
}'

Example Response

{ "status": "ok", "data": {} }

update

Source: backend/endpoints/doctor-wallet-transactions/update

Input Fields

FieldTypeRequiredConstraints
idstringYes-
organizationIdstringYes-
doctorIdstringNonullable
stackUserIdstringNonullable
typestringNonullable
amountnumberNonullable
descriptionstringNonullable
statusstringNonullable
appointmentIdstringNonullable
consultationIdstringNonullable
patientIdstringNonullable
withdrawalMethodstringNonullable
withdrawalDetailsstringNonullable
createdAtintegerNounix-ms timestamp; nullable

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": "doctorWalletTransactions",
  "apiName": "update",
  "data": {
    "id": "id_123",
    "organizationId": "org_123"
  }
}'

Example Response

{ "status": "ok", "data": {} }