CLI rate limit details

paulpharr
paulpharr
Community Member
edited November 2022 in CLI

As I understand it, the APIs supporting the CLI are rate limited to 50000 calls per hour per account or login (is there an exact definition documented somewhere?)

While we are generally well behaved, track our own uuids, and avoid expensive calls, we occasionally run into 429 errors

I am wondering since the CLI abstracts away most REST calls, is there a way to find out dynamically any information about our rate limit status (meaning how many calls we have left in our time window) prior to running into the error? Can we ask the CLI for this metadata directly, or make and event managment REST call and get it from a response header or something?

Is there an obvious or not-so-obvious way to get at this data?

Many thanks,

Paul Pharr


1Password Version: CLI 2 - current release
Extension Version: Not Provided
OS Version: AWS Linux 2
Browser:_ Not Provided

Comments

  • Hi @paulpharr:

    Thanks for reaching out about this. There currently isn't any way of determining your rate limit status. I've shared your feedback on an internal discussion we have on this.

    With that in mind, there are a few ways you can reduce your use of calls when you're using 1Password CLI:

    • Use the --cache flag to avoid requesting the items again.
    • Use item UUIDs wherever possible. In other words, rather than using op item get foo to find the item named foo, use op item get 2xipj35ujypxn4fskjrdq57r5u
    • If you do need to search for an item by name, use --vault to limit to just a single vault, which will avoid fetching the names of all vaults available.

    Thanks again for your feedback!

    Jack

    ref: dev/b5/b5#13414

This discussion has been closed.