Title: Filter syntax 'in_last', 'in_next' - add minute · Issue #385 · shotgunsoftware/python-api · GitHub
Open Graph Title: Filter syntax 'in_last', 'in_next' - add minute · Issue #385 · shotgunsoftware/python-api
X Title: Filter syntax 'in_last', 'in_next' - add minute · Issue #385 · shotgunsoftware/python-api
Description: Currently we are limited by hour,day,week,month,year but often minute is very helpful to allow being more granular. One use case is to query all events that were produced in the last 5 minutes 'in_last' [[int], 'HOUR' | 'DAY' | 'WEEK' | ...
Open Graph Description: Currently we are limited by hour,day,week,month,year but often minute is very helpful to allow being more granular. One use case is to query all events that were produced in the last 5 minutes 'in_...
X Description: Currently we are limited by hour,day,week,month,year but often minute is very helpful to allow being more granular. One use case is to query all events that were produced in the last 5 minutes '...
Opengraph URL: https://github.com/shotgunsoftware/python-api/issues/385
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"Filter syntax 'in_last', 'in_next' - add minute","articleBody":"Currently we are limited by hour,day,week,month,year but often minute is very helpful to allow being more granular.\nOne use case is to query all events that were produced in the last 5 minutes\n\n```\n'in_last' [[int], 'HOUR' | 'DAY' | 'WEEK' | 'MONTH' | 'YEAR']\n # note that brackets are not literal (eg. ['start_date', 'in_last', 1, 'DAY'])\n'in_next' [[int], 'HOUR' | 'DAY' | 'WEEK' | 'MONTH' | 'YEAR']\n # note that brackets are not literal (eg. ['start_date', 'in_next', 1, 'DAY'])\n```\n[link to docs](https://developers.shotgridsoftware.com/python-api/reference.html#operators-and-arguments)\n\nfor those that need minutes until the api supports it\n\n```python\nimport datetime\nfrom datetime import timezone\n\n# Get current time in UTC (which Shotgrid API uses)\nnow = datetime.datetime.now(timezone.utc)\n\n# Calculate timestamp for minutes ago\nminutes_ago = now - datetime.timedelta(minutes=minutes)\n\nfilters = [\n ['created_at', 'greater_than', minutes_ago], # Use timestamp directly\n]\n\n```\n\nThanks!","author":{"url":"https://github.com/patrickwolf","@type":"Person","name":"patrickwolf"},"datePublished":"2025-05-27T20:07:37.000Z","interactionStatistic":{"@type":"InteractionCounter","interactionType":"https://schema.org/CommentAction","userInteractionCount":1},"url":"https://github.com/385/python-api/issues/385"}
| route-pattern | /_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format) |
| route-controller | voltron_issues_fragments |
| route-action | issue_layout |
| fetch-nonce | v2:159c8313-a582-c5f1-c9ca-209d80b180e0 |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | EE22:1B38B1:D1F299:111FC13:696AFEB2 |
| html-safe-nonce | a76ae5d17ea975ab56ddd5fd3653667cc29a0a9cdd3efba544d4725007c0aea5 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJFRTIyOjFCMzhCMTpEMUYyOTk6MTExRkMxMzo2OTZBRkVCMiIsInZpc2l0b3JfaWQiOiIxOTA0NDY0ODIyMzgzODY5NjE4IiwicmVnaW9uX2VkZ2UiOiJpYWQiLCJyZWdpb25fcmVuZGVyIjoiaWFkIn0= |
| visitor-hmac | 2f94905e17419b4c84514196e3a9e2c5698596040d05fe722db2513ec1d2b654 |
| hovercard-subject-tag | issue:3095069919 |
| github-keyboard-shortcuts | repository,issues,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/shotgunsoftware/python-api/385/issue_layout |
| twitter:image | https://opengraph.githubassets.com/ce275a7e6d9968c71ebc2016f27edc2f4fd6ca131de56e434556003167596686/shotgunsoftware/python-api/issues/385 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/ce275a7e6d9968c71ebc2016f27edc2f4fd6ca131de56e434556003167596686/shotgunsoftware/python-api/issues/385 |
| og:image:alt | Currently we are limited by hour,day,week,month,year but often minute is very helpful to allow being more granular. One use case is to query all events that were produced in the last 5 minutes 'in_... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | patrickwolf |
| hostname | github.com |
| expected-hostname | github.com |
| None | 5f99f7c1d70f01da5b93e5ca90303359738944d8ab470e396496262c66e60b8d |
| turbo-cache-control | no-preview |
| go-import | github.com/shotgunsoftware/python-api git https://github.com/shotgunsoftware/python-api.git |
| octolytics-dimension-user_id | 317894 |
| octolytics-dimension-user_login | shotgunsoftware |
| octolytics-dimension-repository_id | 748742 |
| octolytics-dimension-repository_nwo | shotgunsoftware/python-api |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 748742 |
| octolytics-dimension-repository_network_root_nwo | shotgunsoftware/python-api |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | 82560a55c6b2054555076f46e683151ee28a19bc |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width