Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in
Celebration

Earn badges and make progress

You're on your way to the next level! Join the Kudos program to earn points and save your progress.

Deleted user Avatar
Deleted user

Level 1: Seed

25 / 150 points

Next: Root

Avatar

1 badge earned

Collect

Participate in fun challenges

Challenges come and go, but your rewards stay with you. Do more to earn more!

Challenges
Coins

Gift kudos to your peers

What goes around comes around! Share the love by gifting kudos to your peers.

Recognition
Ribbon

Rise up in the ranks

Keep earning points to reach the top of the leaderboard. It resets every quarter so you always have a chance!

Leaderboard

The environments rest API returns an invalid `next` URL when there are more than 10 envs

Daniel Alfaro public
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
Sep 21, 2023

The environments API is returning an odd `next` URL when a repo has more than 10 environments.  This breaks code that is automatically requesting the next URL since it thinks that there are more pages.

 

The response looks like this

```

{

  "page": 1,

  "values": [...],

  "size": 14,

  "next": "http://bitbucket-pipelines.prod.public.atl-paas.net/rest/2.0/accounts/%7B39491fc4-9d08-4885-af60-ad04b4ae7cdb%7D/repositories/%7Bfc0ed7bb-d56a-4e84-b369-9e68a117d2a6%7D/environments?page=2&pagelen=10",

  "pagelen": 14

}

```

 

Attempting to request the URL will result in a 403

1 answer

0 votes
Theodora Boudale
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
Sep 25, 2023

Hi Daniel and welcome to the community.

We have an open bug report about this issue here:

Our development team will post an update on that ticket when this is fixed. Please note that we don't provide ETAs and bug fixing is implemented as per our policy here.

You can add yourself as a watcher (by selecting the Start watching this issue link in the bug report) if you'd like to get notified via email on any updates. You can also select This affects my team to indicate you are affected by this issue.

In the meantime, the only workaround would be to ignore the "next" parameter for this endpoint since the response will show all environments on one page.

Kind regards,
Theodora

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
PERMISSIONS LEVEL
Site Admin
TAGS
AUG Leaders

Atlassian Community Events