@pulumi/github 5.0.0 → 5.2.0-alpha.1673638210

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (260) hide show
  1. package/actionsEnvironmentSecret.d.ts +99 -0
  2. package/actionsEnvironmentSecret.js +68 -24
  3. package/actionsEnvironmentSecret.js.map +1 -1
  4. package/actionsOrganizationPermissions.d.ts +74 -1
  5. package/actionsOrganizationPermissions.js +58 -22
  6. package/actionsOrganizationPermissions.js.map +1 -1
  7. package/actionsOrganizationSecret.d.ts +110 -0
  8. package/actionsOrganizationSecret.js +76 -24
  9. package/actionsOrganizationSecret.js.map +1 -1
  10. package/actionsOrganizationSecretRepositories.d.ts +47 -0
  11. package/actionsOrganizationSecretRepositories.js +51 -22
  12. package/actionsOrganizationSecretRepositories.js.map +1 -1
  13. package/actionsRepositoryPermissions.d.ts +119 -0
  14. package/actionsRepositoryPermissions.js +91 -0
  15. package/actionsRepositoryPermissions.js.map +1 -0
  16. package/actionsRunnerGroup.d.ts +88 -0
  17. package/actionsRunnerGroup.js +47 -22
  18. package/actionsRunnerGroup.js.map +1 -1
  19. package/actionsSecret.d.ts +70 -0
  20. package/actionsSecret.js +48 -24
  21. package/actionsSecret.js.map +1 -1
  22. package/appInstallationRepositories.d.ts +81 -0
  23. package/appInstallationRepositories.js +78 -0
  24. package/appInstallationRepositories.js.map +1 -0
  25. package/appInstallationRepository.d.ts +53 -0
  26. package/appInstallationRepository.js +57 -22
  27. package/appInstallationRepository.js.map +1 -1
  28. package/branch.d.ts +92 -0
  29. package/branch.js +60 -22
  30. package/branch.js.map +1 -1
  31. package/branchDefault.d.ts +53 -0
  32. package/branchDefault.js +57 -22
  33. package/branchDefault.js.map +1 -1
  34. package/branchProtection.d.ts +175 -4
  35. package/branchProtection.js +83 -22
  36. package/branchProtection.js.map +1 -1
  37. package/branchProtectionV3.d.ts +140 -1
  38. package/branchProtectionV3.js +88 -22
  39. package/branchProtectionV3.js.map +1 -1
  40. package/config/vars.d.ts +1 -1
  41. package/config/vars.js.map +1 -1
  42. package/dependabotOrganizationSecret.js +26 -24
  43. package/dependabotOrganizationSecret.js.map +1 -1
  44. package/dependabotOrganizationSecretRepositories.js +22 -22
  45. package/dependabotOrganizationSecretRepositories.js.map +1 -1
  46. package/dependabotSecret.js +26 -24
  47. package/dependabotSecret.js.map +1 -1
  48. package/emuGroupMapping.d.ts +42 -0
  49. package/emuGroupMapping.js +46 -22
  50. package/emuGroupMapping.js.map +1 -1
  51. package/getActionsOrganizationRegistrationToken.d.ts +31 -0
  52. package/getActionsOrganizationRegistrationToken.js +25 -0
  53. package/getActionsOrganizationRegistrationToken.js.map +1 -0
  54. package/getActionsOrganizationSecrets.d.ts +16 -1
  55. package/getActionsOrganizationSecrets.js +13 -4
  56. package/getActionsOrganizationSecrets.js.map +1 -1
  57. package/getActionsPublicKey.d.ts +42 -0
  58. package/getActionsPublicKey.js +32 -5
  59. package/getActionsPublicKey.js.map +1 -1
  60. package/getActionsRegistrationToken.d.ts +67 -0
  61. package/getActionsRegistrationToken.js +47 -0
  62. package/getActionsRegistrationToken.js.map +1 -0
  63. package/getActionsSecrets.d.ts +47 -1
  64. package/getActionsSecrets.js +30 -5
  65. package/getActionsSecrets.js.map +1 -1
  66. package/getBranch.d.ts +51 -0
  67. package/getBranch.js +32 -5
  68. package/getBranch.js.map +1 -1
  69. package/getCollaborators.d.ts +52 -1
  70. package/getCollaborators.js +32 -5
  71. package/getCollaborators.js.map +1 -1
  72. package/getDependabotOrganizationSecrets.d.ts +28 -0
  73. package/getDependabotOrganizationSecrets.js +25 -0
  74. package/getDependabotOrganizationSecrets.js.map +1 -0
  75. package/getDependabotPublicKey.js +2 -5
  76. package/getDependabotPublicKey.js.map +1 -1
  77. package/getDependabotSecrets.d.ts +76 -0
  78. package/getDependabotSecrets.js +49 -0
  79. package/getDependabotSecrets.js.map +1 -0
  80. package/getExternalGroups.d.ts +18 -1
  81. package/getExternalGroups.js +15 -4
  82. package/getExternalGroups.js.map +1 -1
  83. package/getGithubApp.d.ts +71 -0
  84. package/getGithubApp.js +47 -0
  85. package/getGithubApp.js.map +1 -0
  86. package/getIpRanges.d.ts +84 -0
  87. package/getIpRanges.js +13 -4
  88. package/getIpRanges.js.map +1 -1
  89. package/getMembership.d.ts +59 -0
  90. package/getMembership.js +36 -5
  91. package/getMembership.js.map +1 -1
  92. package/getOrganization.d.ts +58 -0
  93. package/getOrganization.js +30 -5
  94. package/getOrganization.js.map +1 -1
  95. package/getOrganizationIpAllowList.d.ts +31 -0
  96. package/getOrganizationIpAllowList.js +27 -0
  97. package/getOrganizationIpAllowList.js.map +1 -0
  98. package/getOrganizationTeamSyncGroups.d.ts +16 -1
  99. package/getOrganizationTeamSyncGroups.js +13 -4
  100. package/getOrganizationTeamSyncGroups.js.map +1 -1
  101. package/getOrganizationTeams.d.ts +87 -1
  102. package/getOrganizationTeams.js +54 -5
  103. package/getOrganizationTeams.js.map +1 -1
  104. package/getOrganizationWebhooks.d.ts +31 -0
  105. package/getOrganizationWebhooks.js +27 -0
  106. package/getOrganizationWebhooks.js.map +1 -0
  107. package/getRef.d.ts +48 -0
  108. package/getRef.js +32 -5
  109. package/getRef.js.map +1 -1
  110. package/getRelease.d.ts +92 -0
  111. package/getRelease.js +8 -5
  112. package/getRelease.js.map +1 -1
  113. package/getRepositories.d.ts +70 -0
  114. package/getRepositories.js +40 -5
  115. package/getRepositories.js.map +1 -1
  116. package/getRepository.d.ts +142 -4
  117. package/getRepository.js +30 -6
  118. package/getRepository.js.map +1 -1
  119. package/getRepositoryBranches.d.ts +82 -0
  120. package/getRepositoryBranches.js +49 -0
  121. package/getRepositoryBranches.js.map +1 -0
  122. package/getRepositoryDeployKeys.d.ts +64 -0
  123. package/getRepositoryDeployKeys.js +47 -0
  124. package/getRepositoryDeployKeys.js.map +1 -0
  125. package/getRepositoryFile.d.ts +72 -0
  126. package/getRepositoryFile.js +36 -5
  127. package/getRepositoryFile.js.map +1 -1
  128. package/getRepositoryMilestone.d.ts +62 -0
  129. package/getRepositoryMilestone.js +34 -5
  130. package/getRepositoryMilestone.js.map +1 -1
  131. package/getRepositoryPullRequest.d.ts +90 -0
  132. package/getRepositoryPullRequest.js +32 -5
  133. package/getRepositoryPullRequest.js.map +1 -1
  134. package/getRepositoryPullRequests.d.ts +91 -1
  135. package/getRepositoryPullRequests.js +38 -5
  136. package/getRepositoryPullRequests.js.map +1 -1
  137. package/getRepositoryTeams.d.ts +47 -1
  138. package/getRepositoryTeams.js +30 -5
  139. package/getRepositoryTeams.js.map +1 -1
  140. package/getRepositoryWebhooks.d.ts +63 -0
  141. package/getRepositoryWebhooks.js +51 -0
  142. package/getRepositoryWebhooks.js.map +1 -0
  143. package/getTeam.d.ts +79 -0
  144. package/getTeam.js +32 -5
  145. package/getTeam.js.map +1 -1
  146. package/getTree.d.ts +70 -1
  147. package/getTree.js +50 -5
  148. package/getTree.js.map +1 -1
  149. package/getUser.d.ts +102 -0
  150. package/getUser.js +38 -5
  151. package/getUser.js.map +1 -1
  152. package/getUsers.d.ts +55 -0
  153. package/getUsers.js +42 -5
  154. package/getUsers.js.map +1 -1
  155. package/index.d.ts +244 -68
  156. package/index.js +259 -171
  157. package/index.js.map +1 -1
  158. package/issue.d.ts +117 -6
  159. package/issue.js +85 -22
  160. package/issue.js.map +1 -1
  161. package/issueLabel.d.ts +64 -0
  162. package/issueLabel.js +44 -22
  163. package/issueLabel.js.map +1 -1
  164. package/membership.d.ts +49 -0
  165. package/membership.js +49 -21
  166. package/membership.js.map +1 -1
  167. package/organizationBlock.d.ts +21 -0
  168. package/organizationBlock.js +31 -19
  169. package/organizationBlock.js.map +1 -1
  170. package/organizationProject.d.ts +36 -0
  171. package/organizationProject.js +32 -20
  172. package/organizationProject.js.map +1 -1
  173. package/organizationSecurityManager.d.ts +67 -0
  174. package/organizationSecurityManager.js +71 -0
  175. package/organizationSecurityManager.js.map +1 -0
  176. package/organizationSettings.d.ts +394 -0
  177. package/organizationSettings.js +148 -0
  178. package/organizationSettings.js.map +1 -0
  179. package/organizationWebhook.d.ts +65 -1
  180. package/organizationWebhook.js +52 -22
  181. package/organizationWebhook.js.map +1 -1
  182. package/package.json +2 -2
  183. package/package.json.dev +2 -2
  184. package/projectCard.d.ts +87 -0
  185. package/projectCard.js +73 -22
  186. package/projectCard.js.map +1 -1
  187. package/projectColumn.d.ts +31 -0
  188. package/projectColumn.js +35 -22
  189. package/projectColumn.js.map +1 -1
  190. package/provider.d.ts +1 -1
  191. package/provider.js +10 -10
  192. package/provider.js.map +1 -1
  193. package/release.d.ts +194 -0
  194. package/release.js +121 -0
  195. package/release.js.map +1 -0
  196. package/repository.d.ts +396 -4
  197. package/repository.js +72 -22
  198. package/repository.js.map +1 -1
  199. package/repositoryAutolinkReference.d.ts +54 -6
  200. package/repositoryAutolinkReference.js +54 -22
  201. package/repositoryAutolinkReference.js.map +1 -1
  202. package/repositoryCollaborator.d.ts +90 -0
  203. package/repositoryCollaborator.js +64 -22
  204. package/repositoryCollaborator.js.map +1 -1
  205. package/repositoryDeployKey.d.ts +71 -0
  206. package/repositoryDeployKey.js +57 -22
  207. package/repositoryDeployKey.js.map +1 -1
  208. package/repositoryEnvironment.d.ts +63 -1
  209. package/repositoryEnvironment.js +56 -22
  210. package/repositoryEnvironment.js.map +1 -1
  211. package/repositoryFile.d.ts +70 -30
  212. package/repositoryFile.js +59 -22
  213. package/repositoryFile.js.map +1 -1
  214. package/repositoryMilestone.d.ts +81 -3
  215. package/repositoryMilestone.js +49 -22
  216. package/repositoryMilestone.js.map +1 -1
  217. package/repositoryProject.d.ts +52 -0
  218. package/repositoryProject.js +41 -22
  219. package/repositoryProject.js.map +1 -1
  220. package/repositoryPullRequest.d.ts +127 -4
  221. package/repositoryPullRequest.js +40 -22
  222. package/repositoryPullRequest.js.map +1 -1
  223. package/repositoryTagProtection.d.ts +41 -0
  224. package/repositoryTagProtection.js +45 -22
  225. package/repositoryTagProtection.js.map +1 -1
  226. package/repositoryWebhook.d.ts +81 -1
  227. package/repositoryWebhook.js +59 -22
  228. package/repositoryWebhook.js.map +1 -1
  229. package/team.d.ts +100 -0
  230. package/team.js +49 -22
  231. package/team.js.map +1 -1
  232. package/teamMembers.d.ts +60 -1
  233. package/teamMembers.js +62 -22
  234. package/teamMembers.js.map +1 -1
  235. package/teamMembership.d.ts +67 -0
  236. package/teamMembership.js +59 -22
  237. package/teamMembership.js.map +1 -1
  238. package/teamRepository.d.ts +59 -3
  239. package/teamRepository.js +57 -22
  240. package/teamRepository.js.map +1 -1
  241. package/teamSettings.d.ts +119 -0
  242. package/teamSettings.js +99 -0
  243. package/teamSettings.js.map +1 -0
  244. package/teamSyncGroupMapping.d.ts +38 -1
  245. package/teamSyncGroupMapping.js +36 -21
  246. package/teamSyncGroupMapping.js.map +1 -1
  247. package/types/index.js.map +1 -1
  248. package/types/input.d.ts +208 -1
  249. package/types/output.d.ts +555 -1
  250. package/userGpgKey.d.ts +39 -0
  251. package/userGpgKey.js +42 -21
  252. package/userGpgKey.js.map +1 -1
  253. package/userInvitationAccepter.d.ts +30 -0
  254. package/userInvitationAccepter.js +38 -17
  255. package/userInvitationAccepter.js.map +1 -1
  256. package/userSshKey.d.ts +50 -0
  257. package/userSshKey.js +48 -22
  258. package/userSshKey.js.map +1 -1
  259. package/utilities.js +13 -1
  260. package/utilities.js.map +1 -1
package/getUser.d.ts CHANGED
@@ -1,45 +1,147 @@
1
1
  import * as pulumi from "@pulumi/pulumi";
2
+ /**
3
+ * Use this data source to retrieve information about a GitHub user.
4
+ *
5
+ * ## Example Usage
6
+ *
7
+ * ```typescript
8
+ * import * as pulumi from "@pulumi/pulumi";
9
+ * import * as github from "@pulumi/github";
10
+ *
11
+ * const example = github.getUser({
12
+ * username: "example",
13
+ * });
14
+ * const current = github.getUser({
15
+ * username: "",
16
+ * });
17
+ * export const currentGithubLogin = current.then(current => current.login);
18
+ * ```
19
+ */
2
20
  export declare function getUser(args: GetUserArgs, opts?: pulumi.InvokeOptions): Promise<GetUserResult>;
3
21
  /**
4
22
  * A collection of arguments for invoking getUser.
5
23
  */
6
24
  export interface GetUserArgs {
25
+ /**
26
+ * The username. Use an empty string `""` to retrieve information about the currently authenticated user.
27
+ */
7
28
  username: string;
8
29
  }
9
30
  /**
10
31
  * A collection of values returned by getUser.
11
32
  */
12
33
  export interface GetUserResult {
34
+ /**
35
+ * the user's avatar URL.
36
+ */
13
37
  readonly avatarUrl: string;
38
+ /**
39
+ * the user's bio.
40
+ */
14
41
  readonly bio: string;
42
+ /**
43
+ * the user's blog location.
44
+ */
15
45
  readonly blog: string;
46
+ /**
47
+ * the user's company name.
48
+ */
16
49
  readonly company: string;
50
+ /**
51
+ * the creation date.
52
+ */
17
53
  readonly createdAt: string;
54
+ /**
55
+ * the user's email.
56
+ */
18
57
  readonly email: string;
58
+ /**
59
+ * the number of followers.
60
+ */
19
61
  readonly followers: number;
62
+ /**
63
+ * the number of following users.
64
+ */
20
65
  readonly following: number;
66
+ /**
67
+ * list of user's GPG keys.
68
+ */
21
69
  readonly gpgKeys: string[];
70
+ /**
71
+ * the user's gravatar ID.
72
+ */
22
73
  readonly gravatarId: string;
23
74
  /**
24
75
  * The provider-assigned unique ID for this managed resource.
25
76
  */
26
77
  readonly id: string;
78
+ /**
79
+ * the user's location.
80
+ */
27
81
  readonly location: string;
82
+ /**
83
+ * the user's login.
84
+ */
28
85
  readonly login: string;
86
+ /**
87
+ * the user's full name.
88
+ */
29
89
  readonly name: string;
90
+ /**
91
+ * the Node ID of the user.
92
+ */
30
93
  readonly nodeId: string;
94
+ /**
95
+ * the number of public gists.
96
+ */
31
97
  readonly publicGists: number;
98
+ /**
99
+ * the number of public repositories.
100
+ */
32
101
  readonly publicRepos: number;
102
+ /**
103
+ * whether the user is a GitHub admin.
104
+ */
33
105
  readonly siteAdmin: boolean;
106
+ /**
107
+ * list of user's SSH keys.
108
+ */
34
109
  readonly sshKeys: string[];
110
+ /**
111
+ * the suspended date if the user is suspended.
112
+ */
35
113
  readonly suspendedAt: string;
114
+ /**
115
+ * the update date.
116
+ */
36
117
  readonly updatedAt: string;
37
118
  readonly username: string;
38
119
  }
120
+ /**
121
+ * Use this data source to retrieve information about a GitHub user.
122
+ *
123
+ * ## Example Usage
124
+ *
125
+ * ```typescript
126
+ * import * as pulumi from "@pulumi/pulumi";
127
+ * import * as github from "@pulumi/github";
128
+ *
129
+ * const example = github.getUser({
130
+ * username: "example",
131
+ * });
132
+ * const current = github.getUser({
133
+ * username: "",
134
+ * });
135
+ * export const currentGithubLogin = current.then(current => current.login);
136
+ * ```
137
+ */
39
138
  export declare function getUserOutput(args: GetUserOutputArgs, opts?: pulumi.InvokeOptions): pulumi.Output<GetUserResult>;
40
139
  /**
41
140
  * A collection of arguments for invoking getUser.
42
141
  */
43
142
  export interface GetUserOutputArgs {
143
+ /**
144
+ * The username. Use an empty string `""` to retrieve information about the currently authenticated user.
145
+ */
44
146
  username: pulumi.Input<string>;
45
147
  }
package/getUser.js CHANGED
@@ -5,18 +5,51 @@ Object.defineProperty(exports, "__esModule", { value: true });
5
5
  exports.getUserOutput = exports.getUser = void 0;
6
6
  const pulumi = require("@pulumi/pulumi");
7
7
  const utilities = require("./utilities");
8
+ /**
9
+ * Use this data source to retrieve information about a GitHub user.
10
+ *
11
+ * ## Example Usage
12
+ *
13
+ * ```typescript
14
+ * import * as pulumi from "@pulumi/pulumi";
15
+ * import * as github from "@pulumi/github";
16
+ *
17
+ * const example = github.getUser({
18
+ * username: "example",
19
+ * });
20
+ * const current = github.getUser({
21
+ * username: "",
22
+ * });
23
+ * export const currentGithubLogin = current.then(current => current.login);
24
+ * ```
25
+ */
8
26
  function getUser(args, opts) {
9
- if (!opts) {
10
- opts = {};
11
- }
12
- opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts);
27
+ opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts || {});
13
28
  return pulumi.runtime.invoke("github:index/getUser:getUser", {
14
29
  "username": args.username,
15
30
  }, opts);
16
31
  }
17
32
  exports.getUser = getUser;
33
+ /**
34
+ * Use this data source to retrieve information about a GitHub user.
35
+ *
36
+ * ## Example Usage
37
+ *
38
+ * ```typescript
39
+ * import * as pulumi from "@pulumi/pulumi";
40
+ * import * as github from "@pulumi/github";
41
+ *
42
+ * const example = github.getUser({
43
+ * username: "example",
44
+ * });
45
+ * const current = github.getUser({
46
+ * username: "",
47
+ * });
48
+ * export const currentGithubLogin = current.then(current => current.login);
49
+ * ```
50
+ */
18
51
  function getUserOutput(args, opts) {
19
- return pulumi.output(args).apply(a => getUser(a, opts));
52
+ return pulumi.output(args).apply((a) => getUser(a, opts));
20
53
  }
21
54
  exports.getUserOutput = getUserOutput;
22
55
  //# sourceMappingURL=getUser.js.map
package/getUser.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"getUser.js","sourceRoot":"","sources":["../getUser.ts"],"names":[],"mappings":";AAAA,wFAAwF;AACxF,iFAAiF;;;AAEjF,yCAAyC;AACzC,yCAAyC;AAEzC,SAAgB,OAAO,CAAC,IAAiB,EAAE,IAA2B;IAClE,IAAI,CAAC,IAAI,EAAE;QACP,IAAI,GAAG,EAAE,CAAA;KACZ;IAED,IAAI,GAAG,MAAM,CAAC,YAAY,CAAC,SAAS,CAAC,oBAAoB,EAAE,EAAE,IAAI,CAAC,CAAC;IACnE,OAAO,MAAM,CAAC,OAAO,CAAC,MAAM,CAAC,8BAA8B,EAAE;QACzD,UAAU,EAAE,IAAI,CAAC,QAAQ;KAC5B,EAAE,IAAI,CAAC,CAAC;AACb,CAAC;AATD,0BASC;AAwCD,SAAgB,aAAa,CAAC,IAAuB,EAAE,IAA2B;IAC9E,OAAO,MAAM,CAAC,MAAM,CAAC,IAAI,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,EAAE,CAAC,OAAO,CAAC,CAAC,EAAE,IAAI,CAAC,CAAC,CAAA;AAC3D,CAAC;AAFD,sCAEC"}
1
+ {"version":3,"file":"getUser.js","sourceRoot":"","sources":["../getUser.ts"],"names":[],"mappings":";AAAA,wFAAwF;AACxF,iFAAiF;;;AAEjF,yCAAyC;AACzC,yCAAyC;AAEzC;;;;;;;;;;;;;;;;;GAiBG;AACH,SAAgB,OAAO,CAAC,IAAiB,EAAE,IAA2B;IAElE,IAAI,GAAG,MAAM,CAAC,YAAY,CAAC,SAAS,CAAC,oBAAoB,EAAE,EAAE,IAAI,IAAI,EAAE,CAAC,CAAC;IACzE,OAAO,MAAM,CAAC,OAAO,CAAC,MAAM,CAAC,8BAA8B,EAAE;QACzD,UAAU,EAAE,IAAI,CAAC,QAAQ;KAC5B,EAAE,IAAI,CAAC,CAAC;AACb,CAAC;AAND,0BAMC;AAsGD;;;;;;;;;;;;;;;;;GAiBG;AACH,SAAgB,aAAa,CAAC,IAAuB,EAAE,IAA2B;IAC9E,OAAO,MAAM,CAAC,MAAM,CAAC,IAAI,CAAC,CAAC,KAAK,CAAC,CAAC,CAAM,EAAE,EAAE,CAAC,OAAO,CAAC,CAAC,EAAE,IAAI,CAAC,CAAC,CAAA;AAClE,CAAC;AAFD,sCAEC"}
package/getUsers.d.ts CHANGED
@@ -1,9 +1,32 @@
1
1
  import * as pulumi from "@pulumi/pulumi";
2
+ /**
3
+ * Use this data source to retrieve information about multiple GitHub users at once.
4
+ *
5
+ * ## Example Usage
6
+ *
7
+ * ```typescript
8
+ * import * as pulumi from "@pulumi/pulumi";
9
+ * import * as github from "@pulumi/github";
10
+ *
11
+ * const example = github.getUsers({
12
+ * usernames: [
13
+ * "example1",
14
+ * "example2",
15
+ * "example3",
16
+ * ],
17
+ * });
18
+ * export const validUsers = example.then(example => example.logins);
19
+ * export const invalidUsers = example.then(example => example.unknownLogins);
20
+ * ```
21
+ */
2
22
  export declare function getUsers(args: GetUsersArgs, opts?: pulumi.InvokeOptions): Promise<GetUsersResult>;
3
23
  /**
4
24
  * A collection of arguments for invoking getUsers.
5
25
  */
6
26
  export interface GetUsersArgs {
27
+ /**
28
+ * List of usernames.
29
+ */
7
30
  usernames: string[];
8
31
  }
9
32
  /**
@@ -14,15 +37,47 @@ export interface GetUsersResult {
14
37
  * The provider-assigned unique ID for this managed resource.
15
38
  */
16
39
  readonly id: string;
40
+ /**
41
+ * list of logins of users that could be found.
42
+ */
17
43
  readonly logins: string[];
44
+ /**
45
+ * list of Node IDs of users that could be found.
46
+ */
18
47
  readonly nodeIds: string[];
48
+ /**
49
+ * list of logins without matching user.
50
+ */
19
51
  readonly unknownLogins: string[];
20
52
  readonly usernames: string[];
21
53
  }
54
+ /**
55
+ * Use this data source to retrieve information about multiple GitHub users at once.
56
+ *
57
+ * ## Example Usage
58
+ *
59
+ * ```typescript
60
+ * import * as pulumi from "@pulumi/pulumi";
61
+ * import * as github from "@pulumi/github";
62
+ *
63
+ * const example = github.getUsers({
64
+ * usernames: [
65
+ * "example1",
66
+ * "example2",
67
+ * "example3",
68
+ * ],
69
+ * });
70
+ * export const validUsers = example.then(example => example.logins);
71
+ * export const invalidUsers = example.then(example => example.unknownLogins);
72
+ * ```
73
+ */
22
74
  export declare function getUsersOutput(args: GetUsersOutputArgs, opts?: pulumi.InvokeOptions): pulumi.Output<GetUsersResult>;
23
75
  /**
24
76
  * A collection of arguments for invoking getUsers.
25
77
  */
26
78
  export interface GetUsersOutputArgs {
79
+ /**
80
+ * List of usernames.
81
+ */
27
82
  usernames: pulumi.Input<pulumi.Input<string>[]>;
28
83
  }
package/getUsers.js CHANGED
@@ -5,18 +5,55 @@ Object.defineProperty(exports, "__esModule", { value: true });
5
5
  exports.getUsersOutput = exports.getUsers = void 0;
6
6
  const pulumi = require("@pulumi/pulumi");
7
7
  const utilities = require("./utilities");
8
+ /**
9
+ * Use this data source to retrieve information about multiple GitHub users at once.
10
+ *
11
+ * ## Example Usage
12
+ *
13
+ * ```typescript
14
+ * import * as pulumi from "@pulumi/pulumi";
15
+ * import * as github from "@pulumi/github";
16
+ *
17
+ * const example = github.getUsers({
18
+ * usernames: [
19
+ * "example1",
20
+ * "example2",
21
+ * "example3",
22
+ * ],
23
+ * });
24
+ * export const validUsers = example.then(example => example.logins);
25
+ * export const invalidUsers = example.then(example => example.unknownLogins);
26
+ * ```
27
+ */
8
28
  function getUsers(args, opts) {
9
- if (!opts) {
10
- opts = {};
11
- }
12
- opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts);
29
+ opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts || {});
13
30
  return pulumi.runtime.invoke("github:index/getUsers:getUsers", {
14
31
  "usernames": args.usernames,
15
32
  }, opts);
16
33
  }
17
34
  exports.getUsers = getUsers;
35
+ /**
36
+ * Use this data source to retrieve information about multiple GitHub users at once.
37
+ *
38
+ * ## Example Usage
39
+ *
40
+ * ```typescript
41
+ * import * as pulumi from "@pulumi/pulumi";
42
+ * import * as github from "@pulumi/github";
43
+ *
44
+ * const example = github.getUsers({
45
+ * usernames: [
46
+ * "example1",
47
+ * "example2",
48
+ * "example3",
49
+ * ],
50
+ * });
51
+ * export const validUsers = example.then(example => example.logins);
52
+ * export const invalidUsers = example.then(example => example.unknownLogins);
53
+ * ```
54
+ */
18
55
  function getUsersOutput(args, opts) {
19
- return pulumi.output(args).apply(a => getUsers(a, opts));
56
+ return pulumi.output(args).apply((a) => getUsers(a, opts));
20
57
  }
21
58
  exports.getUsersOutput = getUsersOutput;
22
59
  //# sourceMappingURL=getUsers.js.map
package/getUsers.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"getUsers.js","sourceRoot":"","sources":["../getUsers.ts"],"names":[],"mappings":";AAAA,wFAAwF;AACxF,iFAAiF;;;AAEjF,yCAAyC;AACzC,yCAAyC;AAEzC,SAAgB,QAAQ,CAAC,IAAkB,EAAE,IAA2B;IACpE,IAAI,CAAC,IAAI,EAAE;QACP,IAAI,GAAG,EAAE,CAAA;KACZ;IAED,IAAI,GAAG,MAAM,CAAC,YAAY,CAAC,SAAS,CAAC,oBAAoB,EAAE,EAAE,IAAI,CAAC,CAAC;IACnE,OAAO,MAAM,CAAC,OAAO,CAAC,MAAM,CAAC,gCAAgC,EAAE;QAC3D,WAAW,EAAE,IAAI,CAAC,SAAS;KAC9B,EAAE,IAAI,CAAC,CAAC;AACb,CAAC;AATD,4BASC;AAuBD,SAAgB,cAAc,CAAC,IAAwB,EAAE,IAA2B;IAChF,OAAO,MAAM,CAAC,MAAM,CAAC,IAAI,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,EAAE,CAAC,QAAQ,CAAC,CAAC,EAAE,IAAI,CAAC,CAAC,CAAA;AAC5D,CAAC;AAFD,wCAEC"}
1
+ {"version":3,"file":"getUsers.js","sourceRoot":"","sources":["../getUsers.ts"],"names":[],"mappings":";AAAA,wFAAwF;AACxF,iFAAiF;;;AAEjF,yCAAyC;AACzC,yCAAyC;AAEzC;;;;;;;;;;;;;;;;;;;GAmBG;AACH,SAAgB,QAAQ,CAAC,IAAkB,EAAE,IAA2B;IAEpE,IAAI,GAAG,MAAM,CAAC,YAAY,CAAC,SAAS,CAAC,oBAAoB,EAAE,EAAE,IAAI,IAAI,EAAE,CAAC,CAAC;IACzE,OAAO,MAAM,CAAC,OAAO,CAAC,MAAM,CAAC,gCAAgC,EAAE;QAC3D,WAAW,EAAE,IAAI,CAAC,SAAS;KAC9B,EAAE,IAAI,CAAC,CAAC;AACb,CAAC;AAND,4BAMC;AAkCD;;;;;;;;;;;;;;;;;;;GAmBG;AACH,SAAgB,cAAc,CAAC,IAAwB,EAAE,IAA2B;IAChF,OAAO,MAAM,CAAC,MAAM,CAAC,IAAI,CAAC,CAAC,KAAK,CAAC,CAAC,CAAM,EAAE,EAAE,CAAC,QAAQ,CAAC,CAAC,EAAE,IAAI,CAAC,CAAC,CAAA;AACnE,CAAC;AAFD,wCAEC"}