meta.credits_used. Failed requests are free. Tracked keywords are a plan allowance, not credits. The cost of each endpoint, from the OpenAPI document (x-credits):
Plans
Credit packs (2,000 for $17, 7,000 for $47, 17,000 for $97) are available on Indie and Studio, never expire and are used after the monthly credits. See pricing.
When a call would cost more than you have left, it fails with 402
insufficient_credits before any work is done.