{"uid":"cap_IUVINprVby8nN2tSGIL61","slug":"matrix-multiplication-api-a346888a","name":"Matrix Multiplication API","description":"Multiply two matrices A·B. The inner dimensions must agree (columns of A equal rows of B); a mismatch or a ragged/empty matrix is a clean 400.","url":"https://matrix.openverbs.com/v1/multiply","method":"POST","headers":{},"bodySchema":{"type":"object","$schema":"https://json-schema.org/draft/2020-12/schema","required":["input"],"properties":{"input":{"type":"object","required":["type","method","bodyType","body"],"properties":{"body":{"type":"object","required":["a","b"],"properties":{"a":{"type":"array","items":{"type":"array","items":{"type":"number"},"minItems":1},"minItems":1,"description":"Left matrix (m×n)."},"b":{"type":"array","items":{"type":"array","items":{"type":"number"},"minItems":1},"minItems":1,"description":"Right matrix (n×p)."}},"additionalProperties":false},"type":{"type":"string","const":"http"},"method":{"enum":["POST"],"type":"string"},"bodyType":{"enum":["json","form-data","text"],"type":"string"}},"additionalProperties":false}}},"responseSchema":null,"example":null,"exampleRequest":null,"tags":["x402"],"displayCostAmount":"0.004","displayCostAsset":"USDC","priceDynamic":false,"priceHint":null,"priceStatus":"priced","priceSource":"probe","requiresHandshake":false,"reviewCount":0,"rating":{"score":"0.00","successRate":"0.00","reviews":0,"stars":null,"state":"unrated"},"availabilityStatus":"unknown","priceObserved":null,"sessionDeposit":null,"pricing":{"kind":"static","summary":"$0.004/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.004","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.004","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_UepzWAcrgyQ0zu5fURJre","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.004","costPer":"request","priority":0,"asset":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","unit":"request","depositMicros":null,"planRef":null}],"brandName":null,"brandSlug":null,"brandBaseUrl":null,"brandDocsUrl":null,"whatItDoes":"Multiplies two matrices A and B (A·B), requiring compatible inner dimensions, and returns the resulting product matrix.","exampleAgentPrompt":"Multiply matrix A = [[1,2],[3,4],[5,6]] by matrix B = [[7,8,9],[10,11,12]] and give me the resulting product matrix.","exampleUseCases":[{"title":"3D graphics transformation pipeline","prompt":"I need to apply a rotation followed by a scaling to a set of 3D points — multiply the rotation matrix [[0,-1,0],[1,0,0],[0,0,1]] by the scaling matrix [[2,0,0],[0,2,0],[0,0,2]] to get the combined transform."},{"title":"Neural network weight layer composition","prompt":"Compose two weight layers in my neural network by multiplying layer W1 = [[0.5,0.1],[0.3,0.9]] by layer W2 = [[1.0,0.0],[0.0,1.0]] so I can compute the forward pass."},{"title":"Economics input-output model calculation","prompt":"Compute the Leontief total requirements by multiplying the technology matrix [[0.2,0.3],[0.1,0.4]] by the demand vector [[100],[200]] to get the output needed for each sector."}],"resultDescription":"Returns the product matrix resulting from A·B as a 2D array of numbers with dimensions m×p, where A is m×n and B is n×p. Returns a clean HTTP 400 error if inner dimensions are mismatched, or if either matrix is ragged or empty.","failureModes":["400 if columns of A do not equal rows of B (dimension mismatch)","400 if either matrix is ragged (rows of unequal length)","400 if either matrix is empty","Numeric precision errors for very large or very small floating-point values"],"whenToPreferThis":"Choose this endpoint when you need a simple, reliable, pay-per-call matrix multiplication with strict input validation and clean error responses. Ideal for agents that need ad-hoc linear algebra without spinning up a compute environment, and when you want guaranteed 400s for bad inputs rather than silent errors or undefined behavior.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-09-15T00:40:00.640Z","isFirstParty":false}