API → PaymentsUpdate balance for an user
hidden

Parameters

Name

Type

Req.

Returns

  • 200 OK

    successful operation

    Name

    Type

    Req.

    body

    object
    optional
    Object Properties
    • created_at

      string / ISO-8601
      optional
    • id

      string / UUID
      optional
    • map_id

      string / UUID
      optional
    • modeling_app_enterprise_price

      oneOf
      optional
      One of
      • flat

        object
        optional
        Object Properties
        • interval

          string
          optional
          Possible values
          • day:  Day.
          • month:  Month.
          • week:  Week.
          • year:  Year.
        • price

          number / USD Price
          optional
        • type

          string
          optional
          Possible values
          • flat
      • per_user

        object
        optional
        Object Properties
        • interval

          string
          optional
          Possible values
          • day:  Day.
          • month:  Month.
          • week:  Week.
          • year:  Year.
        • price

          number / USD Price
          optional
        • type

          string
          optional
          Possible values
          • per_user
      • enterprise

        object
        optional
        Object Properties
        • type

          string
          optional
          Possible values
          • enterprise
    • monthly_credits_remaining

      number / USD Price
      optional
    • pre_pay_cash_remaining

      number / USD Price
      optional
    • pre_pay_credits_remaining

      number / USD Price
      optional
    • subscription_details

      object
      optional
      Object Properties
      • modeling_app

        object
        optional
        Object Properties
        • description

          string
          optional
        • features

          array
          optional
          Array of
        • name

          string
          optional
          Possible values
          • free:  The free tier.
          • pro:  The pro tier.
          • team:  The team tier.
          • enterprise:  The enterprise tier.
        • pay_as_you_go_credits

          number / USD Price
          optional
        • price

          oneOf
          optional
          One of
          • flat

            object
            optional
            Object Properties
            • interval

              string
              optional
              Possible values
              • day:  Day.
              • month:  Month.
              • week:  Week.
              • year:  Year.
            • price

              number / USD Price
              optional
            • type

              string
              optional
              Possible values
              • flat
          • per_user

            object
            optional
            Object Properties
            • interval

              string
              optional
              Possible values
              • day:  Day.
              • month:  Month.
              • week:  Week.
              • year:  Year.
            • price

              number / USD Price
              optional
            • type

              string
              optional
              Possible values
              • per_user
          • enterprise

            object
            optional
            Object Properties
            • type

              string
              optional
              Possible values
              • enterprise
        • support_tier

          string
          optional
          Possible values
          • community:  Community support.
          • standard:  Standard support.
          • premium:  Premium support.
          • priority:  Priority support.
        • Possible values
          • always:  The data is always used for training and cannot be turned off.
          • default_on:  The data is used for training by default, but can be turned off.
          • default_off:  The data is not used for training by default, but can be turned on.
        • type

          oneOf
          optional
          One of
          • individual

            object
            optional
            Object Properties
            • type

              string
              optional
              Possible values
              • individual
          • organization

            object
            optional
            Object Properties
            • saml_sso

              boolean
              optional
            • type

              string
              optional
              Possible values
              • organization
        • zoo_tools_included

          array
          optional
    • subscription_id

      string
      optional
    • total_due

      number / USD Price
      optional
    • updated_at

      string / ISO-8601
      optional
put
/users/{id}/payment/balance
$ curl -X PUT "https://api.zoo.dev/users/{id}/payment/balance" \
	--header "Authorization: Bearer $TOKEN" \
	--header "Content-Type: application/json" \
	--data '{
  "monthly_credits_remaining": "24.40",
  "pre_pay_cash_remaining": "42.12",
  "pre_pay_credits_remaining": "68.23"
}'
200 OK
Response
{
  "created_at": "2024-07-27T01:16:12.261Z",
  "id": "b26b0a4a-303e-49ea-a0ba-66e5d354e60b",
  "map_id": "16a0c1ca-b928-40b9-bebd-6b8221be3e56",
  "modeling_app_enterprise_price": {
    "interval": "day",
    "price": "88.05",
    "type": "per_user"
  },
  "monthly_credits_remaining": "87.56",
  "pre_pay_cash_remaining": "59.87",
  "pre_pay_credits_remaining": "76.09",
  "subscription_details": {
    "modeling_app": {
      "description": "ZDiyBbtGWt7GNG2W533m101R3",
      "features": [
        {
          "info": "Jbk6"
        }
      ],
      "name": "free",
      "pay_as_you_go_credits": "65.30",
      "price": {
        "type": "enterprise"
      },
      "support_tier": "priority",
      "training_data_behavior": "always",
      "type": {
        "type": "individual"
      },
      "zoo_tools_included": [
        "text_to_cad"
      ]
    }
  },
  "subscription_id": "5NkZc5b9O",
  "total_due": "9.34",
  "updated_at": "2024-07-27T01:16:12.262Z"
}