Skip to content

Fix examples & updated API spec#6

Merged
run-o merged 6 commits intomasterfrom
ra-fix-examples
Nov 22, 2017
Merged

Fix examples & updated API spec#6
run-o merged 6 commits intomasterfrom
ra-fix-examples

Conversation

@run-o
Copy link
Copy Markdown
Contributor

@run-o run-o commented Nov 14, 2017

Upgrade swagger-codegen to 2.2.3 and re-generate code: only a minor update from 2.2.2, so no breaking changes.
This fixes an issue where the generated code examples were using the wrong import statement: https://github.com/TheJumpCloud/jumpcloud-issues/issues/1274

Aside from the swagger-codegen changes, the code has been re-generated with the latest API spec files from Stoplight:

  • very minor documentation changes for v1
  • bunch of documentation changes for v2
  • enforced restrictions on associations endpoints for users, systems, user groups and system groups (this basically generates different enums for the accepted types in the models used for associations requests)
  • minor non-breaking changes in the generated code due to the swagger-codegen upgrade

Renaud Amar added 5 commits November 14, 2017 10:26
This fixes an issue where the generated code examples were using the
wrong import statement:
https://github.com/TheJumpCloud/jumpcloud-issues/issues/1274
Using swagger-codegen 2.2.3.
Changes are minimal and non-breaking. Mostly fixes the wrong import
statement in examples and other misc minor changes.
Using swagger-codegen 2.2.3 and latest swagger spec from Stoplight.
- fixes wrong import statement in examples
- apply restrictions for associations on user groups and system groups
endpoints
- bunch of documentation changes in the swagger spec
- other misc minor changes
Comment thread README.md Outdated
try:
# make an API call to retrieve all systemusers:
users = systemusersAPI.systemusers_list(content_type, accept)
print users
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Elsewhere the code is using a print("message") format but here we are not, are examples generated as well?

Copy link
Copy Markdown
Contributor Author

@run-o run-o Nov 16, 2017

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Those are just my own examples. I just added the print statement cause I realized I wasn't doing anything with the result so I might as well print it. I don't think it really matters.

Comment thread README.md Outdated
userGroup = userGroupsAPI.groups_user_get(group_id, content_type, accept)
# make an API call to retrieve all user groups:
userGroups = userGroupsAPI.groups_user_list(content_type, accept)
print userGroups
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same print usage question here

@run-o run-o merged commit 791c89b into master Nov 22, 2017
@run-o run-o deleted the ra-fix-examples branch November 22, 2017 17:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

2 participants