{
  "x402Version": 2,
  "id": 36298,
  "slug": "36298",
  "resource": "https://api.duoleads.com/v1/num/allocate",
  "description": "Split a money amount into shares without losing or inventing a cent. Divide evenly into N parts, or by a list of ratios, and the remainder is distributed one minor unit at a time by a named, deterministic rule — largest-remainder, first-wins or last-wins — so the parts always sum exactly to the original. Uses the ISO 4217 minor-unit exponent of the currency, so zero- and three-decimal currencies work (JPY 0, KWD 3); metals and XXX are rejected.",
  "type": "http",
  "serviceName": "Duo Data Utilities",
  "resourceType": "Monitoring",
  "accepts": [
    {
      "scheme": "exact",
      "network": "eip155:8453",
      "payTo": "0xCD673f7e1daD254347AEab6be0DEFe8b9C6b3A39",
      "asset": "0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913",
      "amount": "50000",
      "amountUsd": 0.05,
      "maxTimeoutSeconds": 120
    }
  ],
  "outputSchema": {
    "properties": {
      "example": {
        "properties": {
          "data": {
            "properties": {
              "currency": {
                "type": "string"
              },
              "minor_units": {
                "type": "integer"
              },
              "remainder_distributed": {
                "type": "integer"
              },
              "rule": {
                "type": "string"
              },
              "shares": {
                "items": {
                  "type": "string"
                },
                "type": "array"
              },
              "shares_minor": {
                "items": {
                  "type": "integer"
                },
                "type": "array"
              },
              "total": {
                "type": "string"
              }
            },
            "required": [
              "shares",
              "shares_minor",
              "total",
              "currency",
              "minor_units",
              "remainder_distributed",
              "rule"
            ],
            "type": "object"
          },
          "meta": {
            "properties": {
              "computed_at": {
                "description": "RFC 3339 UTC with milliseconds",
                "type": "string"
              },
              "deterministic": {
                "type": "boolean"
              },
              "disclaimer": {
                "type": "string"
              },
              "price_usd": {
                "type": "string"
              },
              "request_id": {
                "type": "string"
              },
              "sources": {
                "items": {
                  "required": [
                    "id",
                    "version",
                    "published"
                  ],
                  "type": "object"
                },
                "type": "array"
              }
            },
            "required": [
              "request_id",
              "computed_at",
              "price_usd",
              "deterministic",
              "disclaimer"
            ],
            "type": "object"
          },
          "ok": {
            "const": true
          },
          "route": {
            "const": "/v1/num/allocate"
          },
          "version": {
            "type": "string"
          }
        },
        "required": [
          "ok",
          "route",
          "version",
          "data",
          "meta"
        ],
        "type": "object"
      },
      "type": {
        "type": "string"
      }
    },
    "required": [
      "type"
    ],
    "type": "object"
  },
  "extensions": {
    "bazaar": {
      "info": {
        "input": {
          "method": "GET",
          "queryParams": {
            "amount": "100.00",
            "currency": "EUR",
            "parts": "3"
          },
          "type": "http"
        },
        "output": {
          "example": {
            "data": {
              "currency": "EUR",
              "minor_units": 2,
              "remainder_distributed": 1,
              "rule": "largest-remainder",
              "shares": [
                "33.34",
                "33.33",
                "33.33"
              ],
              "shares_minor": [
                3334,
                3333,
                3333
              ],
              "total": "100.00"
            },
            "meta": {
              "computed_at": "2026-09-28T12:00:00.000Z",
              "deterministic": true,
              "disclaimer": "Factual output of a deterministic computation over public data. Provided as is, with no warranty of accuracy, completeness or availability. Not investment, financial, legal, tax, medical or any other professional advice, and not a recommendation. Verify before relying on it. Terms: https://api.duoleads.com/terms",
              "price_usd": "0.05",
              "request_id": "01K6B7Q4ZC8H3F2M9WXR5TYN0D",
              "sources": [
                {
                  "attribution": "ISO 4217 currency and funds code lists, published by SIX Group as secretariat of the ISO 4217 Maintenance Agency (public data)",
                  "id": "iso-4217",
                  "licence": "Public data (owner decision 2026-09-29)",
                  "published": "2026-09-17",
                  "version": "SIX list one 2026-09-17, list three 2026-01-01"
                }
              ]
            },
            "ok": true,
            "route": "/v1/num/allocate",
            "version": "1.0.0"
          },
          "type": "json"
        }
      },
      "schema": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "properties": {
          "input": {
            "additionalProperties": false,
            "properties": {
              "method": {
                "enum": [
                  "GET"
                ],
                "type": "string"
              },
              "queryParams": {
                "properties": {
                  "amount": {
                    "description": "Decimal amount, absolute value below 1e12.",
                    "maxLength": 24,
                    "type": "string"
                  },
                  "currency": {
                    "description": "ISO 4217 alpha-3 code.",
                    "maxLength": 16,
                    "type": "string"
                  },
                  "parts": {
                    "description": "Number of equal parts, 1-1000. One of parts or ratios.",
                    "maxLength": 64,
                    "pattern": "^[+-]?\\d+$",
                    "type": "string"
                  },
                  "ratios": {
                    "description": "Comma-separated non-negative ratios, at most 1000, each with at most 15 integer digits and 15 decimal places. One of parts or ratios.",
                    "maxLength": 4096,
                    "type": "string"
                  },
                  "rule": {
                    "default": "largest-remainder",
                    "description": "Remainder rule: largest-remainder (default), first, last or round-robin.",
                    "enum": [
                      "largest-remainder",
                      "first",
                      "last",
                      "round-robin"
                    ],
                    "maxLength": 64,
                    "type": "string"
                  }
                },
                "required": [
                  "amount",
                  "currency"
                ],
                "type": "object"
              },
              "type": {
                "const": "http",
                "type": "string"
              }
            },
            "required": [
              "type",
              "method"
            ],
            "type": "object"
          },
          "output": {
            "properties": {
              "example": {
                "properties": {
                  "data": {
                    "properties": {
                      "currency": {
                        "type": "string"
                      },
                      "minor_units": {
                        "type": "integer"
                      },
                      "remainder_distributed": {
                        "type": "integer"
                      },
                      "rule": {
                        "type": "string"
                      },
                      "shares": {
                        "items": {
                          "type": "string"
                        },
                        "type": "array"
                      },
                      "shares_minor": {
                        "items": {
                          "type": "integer"
                        },
                        "type": "array"
                      },
                      "total": {
                        "type": "string"
                      }
                    },
                    "required": [
                      "shares",
                      "shares_minor",
                      "total",
                      "currency",
                      "minor_units",
                      "remainder_distributed",
                      "rule"
                    ],
                    "type": "object"
                  },
                  "meta": {
                    "properties": {
                      "computed_at": {
                        "description": "RFC 3339 UTC with milliseconds",
                        "type": "string"
                      },
                      "deterministic": {
                        "type": "boolean"
                      },
                      "disclaimer": {
                        "type": "string"
                      },
                      "price_usd": {
                        "type": "string"
                      },
                      "request_id": {
                        "type": "string"
                      },
                      "sources": {
                        "items": {
                          "required": [
                            "id",
                            "version",
                            "published"
                          ],
                          "type": "object"
                        },
                        "type": "array"
                      }
                    },
                    "required": [
                      "request_id",
                      "computed_at",
                      "price_usd",
                      "deterministic",
                      "disclaimer"
                    ],
                    "type": "object"
                  },
                  "ok": {
                    "const": true
                  },
                  "route": {
                    "const": "/v1/num/allocate"
                  },
                  "version": {
                    "type": "string"
                  }
                },
                "required": [
                  "ok",
                  "route",
                  "version",
                  "data",
                  "meta"
                ],
                "type": "object"
              },
              "type": {
                "type": "string"
              }
            },
            "required": [
              "type"
            ],
            "type": "object"
          }
        },
        "required": [
          "input"
        ],
        "type": "object"
      }
    }
  },
  "tags": [
    "deterministic",
    "no-api-key",
    "num",
    "finance",
    "money",
    "bazaar"
  ],
  "sourceHost": "api.duoleads.com",
  "lastUpdated": "2026-10-01T20:53:43.613Z",
  "quality": {
    "calls30d": 2,
    "uniquePayers30d": 1,
    "lastCalledAt": "2026-10-01T20:53:43.493Z"
  },
  "metadata": {
    "serviceName": "Duo Data Utilities",
    "extensions": {
      "bazaar": {
        "info": {
          "input": {
            "method": "GET",
            "queryParams": {
              "amount": "100.00",
              "currency": "EUR",
              "parts": "3"
            },
            "type": "http"
          },
          "output": {
            "example": {
              "data": {
                "currency": "EUR",
                "minor_units": 2,
                "remainder_distributed": 1,
                "rule": "largest-remainder",
                "shares": [
                  "33.34",
                  "33.33",
                  "33.33"
                ],
                "shares_minor": [
                  3334,
                  3333,
                  3333
                ],
                "total": "100.00"
              },
              "meta": {
                "computed_at": "2026-09-28T12:00:00.000Z",
                "deterministic": true,
                "disclaimer": "Factual output of a deterministic computation over public data. Provided as is, with no warranty of accuracy, completeness or availability. Not investment, financial, legal, tax, medical or any other professional advice, and not a recommendation. Verify before relying on it. Terms: https://api.duoleads.com/terms",
                "price_usd": "0.05",
                "request_id": "01K6B7Q4ZC8H3F2M9WXR5TYN0D",
                "sources": [
                  {
                    "attribution": "ISO 4217 currency and funds code lists, published by SIX Group as secretariat of the ISO 4217 Maintenance Agency (public data)",
                    "id": "iso-4217",
                    "licence": "Public data (owner decision 2026-09-29)",
                    "published": "2026-09-17",
                    "version": "SIX list one 2026-09-17, list three 2026-01-01"
                  }
                ]
              },
              "ok": true,
              "route": "/v1/num/allocate",
              "version": "1.0.0"
            },
            "type": "json"
          }
        },
        "schema": {
          "$schema": "https://json-schema.org/draft/2020-12/schema",
          "properties": {
            "input": {
              "additionalProperties": false,
              "properties": {
                "method": {
                  "enum": [
                    "GET"
                  ],
                  "type": "string"
                },
                "queryParams": {
                  "properties": {
                    "amount": {
                      "description": "Decimal amount, absolute value below 1e12.",
                      "maxLength": 24,
                      "type": "string"
                    },
                    "currency": {
                      "description": "ISO 4217 alpha-3 code.",
                      "maxLength": 16,
                      "type": "string"
                    },
                    "parts": {
                      "description": "Number of equal parts, 1-1000. One of parts or ratios.",
                      "maxLength": 64,
                      "pattern": "^[+-]?\\d+$",
                      "type": "string"
                    },
                    "ratios": {
                      "description": "Comma-separated non-negative ratios, at most 1000, each with at most 15 integer digits and 15 decimal places. One of parts or ratios.",
                      "maxLength": 4096,
                      "type": "string"
                    },
                    "rule": {
                      "default": "largest-remainder",
                      "description": "Remainder rule: largest-remainder (default), first, last or round-robin.",
                      "enum": [
                        "largest-remainder",
                        "first",
                        "last",
                        "round-robin"
                      ],
                      "maxLength": 64,
                      "type": "string"
                    }
                  },
                  "required": [
                    "amount",
                    "currency"
                  ],
                  "type": "object"
                },
                "type": {
                  "const": "http",
                  "type": "string"
                }
              },
              "required": [
                "type",
                "method"
              ],
              "type": "object"
            },
            "output": {
              "properties": {
                "example": {
                  "properties": {
                    "data": {
                      "properties": {
                        "currency": {
                          "type": "string"
                        },
                        "minor_units": {
                          "type": "integer"
                        },
                        "remainder_distributed": {
                          "type": "integer"
                        },
                        "rule": {
                          "type": "string"
                        },
                        "shares": {
                          "items": {
                            "type": "string"
                          },
                          "type": "array"
                        },
                        "shares_minor": {
                          "items": {
                            "type": "integer"
                          },
                          "type": "array"
                        },
                        "total": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "shares",
                        "shares_minor",
                        "total",
                        "currency",
                        "minor_units",
                        "remainder_distributed",
                        "rule"
                      ],
                      "type": "object"
                    },
                    "meta": {
                      "properties": {
                        "computed_at": {
                          "description": "RFC 3339 UTC with milliseconds",
                          "type": "string"
                        },
                        "deterministic": {
                          "type": "boolean"
                        },
                        "disclaimer": {
                          "type": "string"
                        },
                        "price_usd": {
                          "type": "string"
                        },
                        "request_id": {
                          "type": "string"
                        },
                        "sources": {
                          "items": {
                            "required": [
                              "id",
                              "version",
                              "published"
                            ],
                            "type": "object"
                          },
                          "type": "array"
                        }
                      },
                      "required": [
                        "request_id",
                        "computed_at",
                        "price_usd",
                        "deterministic",
                        "disclaimer"
                      ],
                      "type": "object"
                    },
                    "ok": {
                      "const": true
                    },
                    "route": {
                      "const": "/v1/num/allocate"
                    },
                    "version": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "ok",
                    "route",
                    "version",
                    "data",
                    "meta"
                  ],
                  "type": "object"
                },
                "type": {
                  "type": "string"
                }
              },
              "required": [
                "type"
              ],
              "type": "object"
            }
          },
          "required": [
            "input"
          ],
          "type": "object"
        }
      }
    }
  },
  "liveness": {
    "reliability": null
  },
  "verified": false,
  "featured": false,
  "provider": {
    "host": "api.duoleads.com",
    "manifest_name": "api.duoleads.com",
    "source": "cdp-mirror",
    "source_manifest_url": "https://api.cdp.coinbase.com/platform/v2/x402/discovery/resources",
    "submitted_at": "2026-10-14T01:15:01.050Z"
  },
  "exampleResponse": {
    "example": {
      "data": {
        "currency": "string",
        "minor_units": 0,
        "remainder_distributed": 0,
        "rule": "string",
        "shares": [
          "string"
        ],
        "shares_minor": [
          0
        ],
        "total": "string"
      },
      "meta": {
        "computed_at": "string",
        "deterministic": true,
        "disclaimer": "string",
        "price_usd": "string",
        "request_id": "string",
        "sources": [
          {}
        ]
      },
      "ok": null,
      "route": null,
      "version": "string"
    },
    "type": "string"
  }
}