{"id":19944410,"url":"https://github.com/dataform-co/dataform-bq-audit-logs","last_synced_at":"2026-05-12T11:34:43.158Z","repository":{"id":81643253,"uuid":"234582009","full_name":"dataform-co/dataform-bq-audit-logs","owner":"dataform-co","description":null,"archived":false,"fork":false,"pushed_at":"2023-07-17T09:04:09.000Z","size":29,"stargazers_count":1,"open_issues_count":0,"forks_count":2,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-01-12T05:11:23.620Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/dataform-co.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2020-01-17T15:55:13.000Z","updated_at":"2022-06-07T15:58:14.000Z","dependencies_parsed_at":null,"dependency_job_id":"f6ee9a7f-5ac1-4e4a-939c-13c456ebfbe5","html_url":"https://github.com/dataform-co/dataform-bq-audit-logs","commit_stats":null,"previous_names":[],"tags_count":4,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dataform-co%2Fdataform-bq-audit-logs","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dataform-co%2Fdataform-bq-audit-logs/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dataform-co%2Fdataform-bq-audit-logs/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dataform-co%2Fdataform-bq-audit-logs/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/dataform-co","download_url":"https://codeload.github.com/dataform-co/dataform-bq-audit-logs/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":241374518,"owners_count":19952544,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-13T00:20:35.156Z","updated_at":"2026-05-12T11:34:38.119Z","avatar_url":"https://github.com/dataform-co.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"\n**** NOTE: This package was created before the \"Jobs\" information schema tables were available in BigQuery. ****\n**** We recommended that you use the information schema tables instead of this package                      ****\n**** Learn more: https://cloud.google.com/bigquery/docs/information-schema-jobs                             ****\n\n\nThis package creates a simple dataset to aid analysis of BigQuery usage logs.\n\nTo set up BigQuery audit data logging, follow the instructions [here](https://dataform.co/blog/exporting-bigquery-usage-logs).\n\n\u003cdiv style=\"position: relative; padding-bottom: 56.25%; height: 0;\"\u003e\u003ciframe src=\"https://www.loom.com/embed/fdfa25dcdc8544e38fe844199b970f87\" frameborder=\"0\" webkitallowfullscreen mozallowfullscreen allowfullscreen style=\"position: absolute; top: 0; left: 0; width: 100%; height: 100%;\"\u003e\u003c/iframe\u003e\u003c/div\u003e\n\n## Supported warehouses\n\n- BigQuery\n\n## Installation\n\nAdd the package to your `package.json` file in your Dataform project. You can find the most up to package version on the [releases page](https://github.com/dataform-co/dataform-bq-audit-logs/releases).\n\n## Configure the package\n\nCreate a new JS file in your `definitions/` folder and create the BigQuery table with the following snippet:\n\n```js\nconst bigQueryLogs = require(\"dataform-bigquery-logs\");\n\nconst bigQueryLogsModels = bigQueryLogs({\n  logsSchema: \"stackdriver_logs\",\n  defaultConfig: {\n    tags: [\"bq_audit_logs\"],\n    type: \"view\"\n  },\n});\n```\n\nFor more advanced uses cases, see the [example.js](https://github.com/dataform-co/dataform-bq-audit-logs/blob/master/definitions/example.js).\n\n## Data models\n\nThis output of this package is the following data model (configurable as tables or views).\n\n### `bigquery_compute_logs`\n\nOne row for every query log sent from BigQuery to stackdriver. The schema of this table is significantly simplified as compared to the raw logs table!\n\n\u003cimg src=\"https://assets.dataform.co/docs/packages/bq-audit-logs/bq-audit-logs-dag.png\" /\u003e\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdataform-co%2Fdataform-bq-audit-logs","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdataform-co%2Fdataform-bq-audit-logs","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdataform-co%2Fdataform-bq-audit-logs/lists"}