Coder Social home page Coder Social logo

Comments (8)

bretterer avatar bretterer commented on June 23, 2024 1

We have recently released a 1.x version of this SDK and all api calls and setup is different which should resolve this issue. Please check out our new version on PyPi.

This new release includes pagination capabilities which should resolve this issue for you.

If you find that you are still having an issue, please let us know if you are still having this issue.

from okta-sdk-python.

serhiibuniak-okta avatar serhiibuniak-okta commented on June 23, 2024 1

@Andrey-Danilenko Yes, 200 is a hard limit and you have to use pagination (it doesn't depend on SDK). How to use pagination with Python SDK - https://github.com/okta/okta-sdk-python#pagination

from okta-sdk-python.

nbarbettini avatar nbarbettini commented on June 23, 2024

You're only getting 1 page of results (see Pagination). For both Postman and Python code, you need to keep retrieving pages by repeatedly grabbing the next link from the Location header until there isn't a next link anymore.

from okta-sdk-python.

Mogost avatar Mogost commented on June 23, 2024

Thank you @nbarbettini, but I know about Pagination.
But code in that library does not work with pagination.
https://github.com/okta/okta-sdk-python/blob/master/okta/UserGroupsClient.py#L64

    def get_group_users(self, gid):
        response = ApiClient.get_path(self, '/{0}/users'.format(gid))
        return Utils.deserialize(response.text, User)

from okta-sdk-python.

nbarbettini avatar nbarbettini commented on June 23, 2024

Ah, I gotcha. Sorry about that. This library is not currently being maintained, so you will have to write your own pagination code. You could look at get_paged_users for inspiration: https://github.com/okta/okta-sdk-python/blob/master/okta/UsersClient.py#L106-L128

from okta-sdk-python.

Mogost avatar Mogost commented on June 23, 2024

TY. I have already solved the problem in this way. This is just a issue to fix in the future. Perhaps I will make a pullrequest if I have time.

from okta-sdk-python.

nbarbettini avatar nbarbettini commented on June 23, 2024

👍 Thanks for reporting! I'll leave this open, although we aren't currently planning any Python work in the near future.

from okta-sdk-python.

Andrey-Danilenko avatar Andrey-Danilenko commented on June 23, 2024

@bretterer Hello! I've got the several problem in SDK ver. 1.6.0
I used OktaClient::list_group_users() method and got only 200 records. I tried to use query_params.limit, but it worked only with numbers lesser than 200. Seems like 200 is a hard limit, and SDK force me to use pagination. Can I off the pagination or set limit more than 200 in some way?
Thank you!

from okta-sdk-python.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.