Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add api_limit field to provider configuration #872

Closed
wants to merge 2 commits into from

Conversation

jordynsamuel
Copy link

@jordynsamuel jordynsamuel commented May 17, 2024

Assuming a service named hello, and 25 other services in the pattern *hello, when using the following data block:

data "pagerduty_service" "hello" {
    name = "hello"
}

It will fail with the message:

Error: Unable to locate any service with the name: hello

This is because the API call to locate the service, by default, has a pagination limit of 25, thus the service is excluded since it appears on the 2nd page.

This PR adds an api_limit field to the provider to allow a pagination limit to be set.

It can be used as such:

provider "pagerduty" {
  token = "your_token"
  api_limit = 50 // default 25
}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant