Created
July 18, 2018 21:17
-
-
Save jamesmartin/57d09d40f9f93d85ccd44e791aa0a96f to your computer and use it in GitHub Desktop.
Listing all External Identities of a SAML enabled GitHub Organization
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
query($login: String!) { | |
organization(login: $login) { | |
... on Organization { | |
samlIdentityProvider { | |
externalIdentities(first: 30) { | |
edges { | |
node { | |
samlIdentity { | |
nameId | |
} | |
user { | |
login | |
} | |
} | |
} | |
} | |
} | |
} | |
} | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"data": { | |
"organization": { | |
"samlIdentityProvider": { | |
"externalIdentities": { | |
"edges": [ | |
{ | |
"node": { | |
"samlIdentity": { | |
"nameId": "jamesmartin" | |
}, | |
"user": { | |
"login": "jamesmartin" | |
} | |
} | |
}, | |
{ | |
"node": { | |
"samlIdentity": { | |
"nameId": "[email protected]" | |
}, | |
"user": { | |
"login": "mtodd" | |
} | |
} | |
} | |
] | |
} | |
} | |
} | |
} | |
} |
What if you have 1000 entries?
What if you have 1000 entries?
You could try paging through the entries using a cursor.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Use input: