{ "db_name": "PostgreSQL", "query": "SELECT COALESCE(SUM(tokens_in), 0)::BIGINT AS \"tokens_in!\",\n COALESCE(SUM(tokens_out), 0)::BIGINT AS \"tokens_out!\",\n COALESCE(SUM(credits), 0)::BIGINT AS \"credits!\"\n FROM usage_events\n WHERE workspace_id = $1 AND created_at > now() - interval '7 days'", "describe": { "columns": [ { "ordinal": 0, "name": "tokens_in!", "type_info": "Int8" }, { "ordinal": 1, "name": "tokens_out!", "type_info": "Int8" }, { "ordinal": 2, "name": "credits!", "type_info": "Int8" } ], "parameters": { "Left": [ "Uuid" ] }, "nullable": [ null, null, null ] }, "hash": "909cb1586b68326590bd3b399bf3284b9084585e3b6fa6d92393c76c0d2f9534" }