Skip to content

armgit / macro

Public Imported from GitHub
0

Macro is a unified workspace for teams: email, chat, docs, tasks, agents, calls, and CRM — @-linked together with shared AI memory.

1.2 KB
Raw Blame
{
  "db_name": "PostgreSQL",
  "query": "\n            SELECT DISTINCT user_id AS \"user_id!\"\n            FROM (\n                SELECT user_id\n                FROM ai_usage\n                WHERE count_usage = TRUE\n                  AND created_at >= $1\n                UNION ALL\n                SELECT user_id\n                FROM ai_credit_reload\n                WHERE kind = 'automatic'\n                  AND status = 'pending'\n                  AND stripe_invoice_id IS NULL\n                  AND updated_at < $2::timestamptz - INTERVAL '10 minutes'\n                UNION ALL\n                SELECT user_id\n                FROM ai_billing_account\n                WHERE period_start >= $1::timestamptz\n                   OR (period_end >= $1 AND period_end <= $2)\n            ) AS candidates\n            ORDER BY user_id\n            ",
  "describe": {
    "columns": [
      {
        "ordinal": 0,
        "name": "user_id!",
        "type_info": "Text"
      }
    ],
    "parameters": {
      "Left": [
        "Timestamptz",
        "Timestamptz"
      ]
    },
    "nullable": [
      null
    ]
  },
  "hash": "da846c9c7acf83aff9446fd6c905cc08784f137c8b2e84d028639ba60c5451d5"
}