auth0 5.9.1 → 5.11.0

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 (394) hide show
  1. package/dist/cjs/management/BaseClient.d.ts +3 -0
  2. package/dist/cjs/management/BaseClient.js +15 -0
  3. package/dist/cjs/management/Client.d.ts +3 -0
  4. package/dist/cjs/management/Client.js +41 -36
  5. package/dist/cjs/management/api/requests/requests.d.ts +281 -3
  6. package/dist/cjs/management/api/resources/actions/client/Client.d.ts +1 -1
  7. package/dist/cjs/management/api/resources/actions/client/Client.js +1 -1
  8. package/dist/cjs/management/api/resources/branding/resources/templates/client/Client.d.ts +16 -16
  9. package/dist/cjs/management/api/resources/branding/resources/templates/client/Client.js +16 -16
  10. package/dist/cjs/management/api/resources/clients/client/Client.d.ts +12 -3
  11. package/dist/cjs/management/api/resources/clients/client/Client.js +12 -3
  12. package/dist/cjs/management/api/resources/connections/client/Client.d.ts +17 -19
  13. package/dist/cjs/management/api/resources/connections/client/Client.js +17 -19
  14. package/dist/cjs/management/api/resources/connections/resources/clients/client/Client.d.ts +2 -2
  15. package/dist/cjs/management/api/resources/connections/resources/clients/client/Client.js +2 -2
  16. package/dist/cjs/management/api/resources/connections/resources/scimConfiguration/client/Client.d.ts +4 -4
  17. package/dist/cjs/management/api/resources/connections/resources/scimConfiguration/client/Client.js +4 -4
  18. package/dist/cjs/management/api/resources/connections/resources/scimConfiguration/resources/tokens/client/Client.d.ts +2 -2
  19. package/dist/cjs/management/api/resources/connections/resources/scimConfiguration/resources/tokens/client/Client.js +2 -2
  20. package/dist/cjs/management/api/resources/customDomains/client/Client.d.ts +19 -12
  21. package/dist/cjs/management/api/resources/customDomains/client/Client.js +19 -12
  22. package/dist/cjs/management/api/resources/deviceCredentials/client/Client.d.ts +3 -3
  23. package/dist/cjs/management/api/resources/deviceCredentials/client/Client.js +3 -3
  24. package/dist/cjs/management/api/resources/groups/client/Client.d.ts +3 -0
  25. package/dist/cjs/management/api/resources/groups/client/Client.js +5 -0
  26. package/dist/cjs/management/api/resources/groups/resources/index.d.ts +1 -0
  27. package/dist/cjs/management/api/resources/groups/resources/index.js +2 -1
  28. package/dist/cjs/management/api/resources/groups/resources/roles/client/Client.d.ts +71 -0
  29. package/dist/cjs/management/api/resources/groups/resources/roles/client/Client.js +270 -0
  30. package/dist/cjs/management/api/resources/groups/resources/roles/client/index.d.ts +1 -0
  31. package/dist/cjs/management/api/resources/groups/resources/roles/client/index.js +2 -0
  32. package/dist/cjs/management/api/resources/groups/resources/roles/index.d.ts +1 -0
  33. package/dist/cjs/management/api/resources/groups/resources/roles/index.js +17 -0
  34. package/dist/cjs/management/api/resources/guardian/resources/enrollments/client/Client.d.ts +2 -5
  35. package/dist/cjs/management/api/resources/guardian/resources/enrollments/client/Client.js +2 -5
  36. package/dist/cjs/management/api/resources/guardian/resources/factors/resources/pushNotification/client/Client.d.ts +3 -3
  37. package/dist/cjs/management/api/resources/guardian/resources/factors/resources/pushNotification/client/Client.js +3 -3
  38. package/dist/cjs/management/api/resources/guardian/resources/policies/client/Client.d.ts +10 -12
  39. package/dist/cjs/management/api/resources/guardian/resources/policies/client/Client.js +10 -12
  40. package/dist/cjs/management/api/resources/hooks/client/Client.d.ts +2 -2
  41. package/dist/cjs/management/api/resources/hooks/client/Client.js +2 -2
  42. package/dist/cjs/management/api/resources/index.d.ts +1 -0
  43. package/dist/cjs/management/api/resources/index.js +2 -1
  44. package/dist/cjs/management/api/resources/jobs/resources/verificationEmail/client/Client.d.ts +1 -1
  45. package/dist/cjs/management/api/resources/jobs/resources/verificationEmail/client/Client.js +1 -1
  46. package/dist/cjs/management/api/resources/logs/client/Client.d.ts +17 -20
  47. package/dist/cjs/management/api/resources/logs/client/Client.js +17 -20
  48. package/dist/cjs/management/api/resources/organizations/client/Client.d.ts +14 -13
  49. package/dist/cjs/management/api/resources/organizations/client/Client.js +20 -17
  50. package/dist/cjs/management/api/resources/organizations/resources/discoveryDomains/client/Client.d.ts +1 -1
  51. package/dist/cjs/management/api/resources/organizations/resources/discoveryDomains/client/Client.js +1 -1
  52. package/dist/cjs/management/api/resources/organizations/resources/enabledConnections/client/Client.d.ts +2 -2
  53. package/dist/cjs/management/api/resources/organizations/resources/enabledConnections/client/Client.js +2 -2
  54. package/dist/cjs/management/api/resources/organizations/resources/groups/client/Client.d.ts +35 -0
  55. package/dist/cjs/management/api/resources/organizations/resources/groups/client/Client.js +146 -0
  56. package/dist/cjs/management/api/resources/organizations/resources/groups/client/index.d.ts +1 -0
  57. package/dist/cjs/management/api/resources/organizations/resources/groups/client/index.js +2 -0
  58. package/dist/cjs/management/api/resources/organizations/resources/groups/index.d.ts +2 -0
  59. package/dist/cjs/management/api/resources/organizations/resources/groups/index.js +18 -0
  60. package/dist/cjs/management/api/resources/organizations/resources/groups/resources/index.d.ts +1 -0
  61. package/dist/cjs/management/api/resources/organizations/resources/groups/resources/index.js +37 -0
  62. package/dist/cjs/management/api/resources/organizations/resources/groups/resources/roles/client/Client.d.ts +74 -0
  63. package/dist/cjs/management/api/resources/organizations/resources/groups/resources/roles/client/Client.js +273 -0
  64. package/dist/cjs/management/api/resources/organizations/resources/groups/resources/roles/client/index.d.ts +1 -0
  65. package/dist/cjs/management/api/resources/organizations/resources/groups/resources/roles/client/index.js +2 -0
  66. package/dist/cjs/management/api/resources/organizations/resources/groups/resources/roles/index.d.ts +1 -0
  67. package/dist/cjs/management/api/resources/organizations/resources/groups/resources/roles/index.js +17 -0
  68. package/dist/cjs/management/api/resources/organizations/resources/index.d.ts +1 -0
  69. package/dist/cjs/management/api/resources/organizations/resources/index.js +2 -1
  70. package/dist/cjs/management/api/resources/organizations/resources/invitations/client/Client.d.ts +2 -2
  71. package/dist/cjs/management/api/resources/organizations/resources/invitations/client/Client.js +2 -2
  72. package/dist/cjs/management/api/resources/organizations/resources/members/client/Client.d.ts +9 -12
  73. package/dist/cjs/management/api/resources/organizations/resources/members/client/Client.js +13 -14
  74. package/dist/cjs/management/api/resources/organizations/resources/members/resources/effectiveRoles/client/Client.d.ts +36 -0
  75. package/dist/cjs/management/api/resources/organizations/resources/members/resources/effectiveRoles/client/Client.js +147 -0
  76. package/dist/cjs/management/api/resources/organizations/resources/members/resources/effectiveRoles/client/index.d.ts +1 -0
  77. package/dist/cjs/management/api/resources/organizations/resources/members/resources/effectiveRoles/client/index.js +2 -0
  78. package/dist/cjs/management/api/resources/organizations/resources/members/resources/effectiveRoles/index.d.ts +2 -0
  79. package/dist/cjs/management/api/resources/organizations/resources/members/resources/effectiveRoles/index.js +18 -0
  80. package/dist/cjs/management/api/resources/organizations/resources/members/resources/effectiveRoles/resources/index.d.ts +1 -0
  81. package/dist/cjs/management/api/resources/organizations/resources/members/resources/effectiveRoles/resources/index.js +37 -0
  82. package/dist/cjs/management/api/resources/organizations/resources/members/resources/effectiveRoles/resources/sources/client/Client.d.ts +12 -0
  83. package/dist/cjs/management/api/resources/organizations/resources/members/resources/effectiveRoles/resources/sources/client/Client.js +16 -0
  84. package/dist/cjs/management/api/resources/organizations/resources/members/resources/effectiveRoles/resources/sources/client/index.d.ts +1 -0
  85. package/dist/cjs/management/api/resources/organizations/resources/members/resources/effectiveRoles/resources/sources/client/index.js +2 -0
  86. package/dist/cjs/management/api/resources/organizations/resources/members/resources/effectiveRoles/resources/sources/index.d.ts +2 -0
  87. package/dist/cjs/management/api/resources/organizations/resources/members/resources/effectiveRoles/resources/sources/index.js +18 -0
  88. package/dist/cjs/management/api/resources/organizations/resources/members/resources/effectiveRoles/resources/sources/resources/groups/client/Client.d.ts +34 -0
  89. package/dist/cjs/management/api/resources/organizations/resources/members/resources/effectiveRoles/resources/sources/resources/groups/client/Client.js +144 -0
  90. package/dist/cjs/management/api/resources/organizations/resources/members/resources/effectiveRoles/resources/sources/resources/groups/client/index.d.ts +1 -0
  91. package/dist/cjs/management/api/resources/organizations/resources/members/resources/effectiveRoles/resources/sources/resources/groups/client/index.js +2 -0
  92. package/dist/cjs/management/api/resources/organizations/resources/members/resources/effectiveRoles/resources/sources/resources/groups/index.d.ts +1 -0
  93. package/dist/cjs/management/api/resources/organizations/resources/members/resources/effectiveRoles/resources/sources/resources/groups/index.js +17 -0
  94. package/dist/cjs/management/api/resources/organizations/resources/members/resources/effectiveRoles/resources/sources/resources/index.d.ts +1 -0
  95. package/dist/cjs/management/api/resources/organizations/resources/members/resources/effectiveRoles/resources/sources/resources/index.js +37 -0
  96. package/dist/cjs/management/api/resources/organizations/resources/members/resources/index.d.ts +1 -0
  97. package/dist/cjs/management/api/resources/organizations/resources/members/resources/index.js +2 -1
  98. package/dist/cjs/management/api/resources/organizations/resources/members/resources/roles/client/Client.d.ts +2 -2
  99. package/dist/cjs/management/api/resources/organizations/resources/members/resources/roles/client/Client.js +2 -2
  100. package/dist/cjs/management/api/resources/prompts/resources/rendering/client/Client.d.ts +2 -2
  101. package/dist/cjs/management/api/resources/prompts/resources/rendering/client/Client.js +2 -2
  102. package/dist/cjs/management/api/resources/rateLimitPolicies/client/Client.d.ts +102 -0
  103. package/dist/cjs/management/api/resources/rateLimitPolicies/client/Client.js +397 -0
  104. package/dist/cjs/management/api/resources/rateLimitPolicies/client/index.d.ts +1 -0
  105. package/dist/cjs/management/api/resources/rateLimitPolicies/client/index.js +2 -0
  106. package/dist/cjs/management/api/resources/rateLimitPolicies/index.d.ts +1 -0
  107. package/dist/cjs/management/api/resources/rateLimitPolicies/index.js +17 -0
  108. package/dist/cjs/management/api/resources/roles/client/Client.d.ts +9 -6
  109. package/dist/cjs/management/api/resources/roles/client/Client.js +15 -10
  110. package/dist/cjs/management/api/resources/roles/resources/groups/client/Client.d.ts +71 -0
  111. package/dist/cjs/management/api/resources/roles/resources/groups/client/Client.js +270 -0
  112. package/dist/cjs/management/api/resources/roles/resources/groups/client/index.d.ts +1 -0
  113. package/dist/cjs/management/api/resources/roles/resources/groups/client/index.js +2 -0
  114. package/dist/cjs/management/api/resources/roles/resources/groups/index.d.ts +1 -0
  115. package/dist/cjs/management/api/resources/roles/resources/groups/index.js +17 -0
  116. package/dist/cjs/management/api/resources/roles/resources/index.d.ts +1 -0
  117. package/dist/cjs/management/api/resources/roles/resources/index.js +2 -1
  118. package/dist/cjs/management/api/resources/roles/resources/permissions/client/Client.d.ts +2 -2
  119. package/dist/cjs/management/api/resources/roles/resources/permissions/client/Client.js +2 -2
  120. package/dist/cjs/management/api/resources/roles/resources/users/client/Client.d.ts +11 -13
  121. package/dist/cjs/management/api/resources/roles/resources/users/client/Client.js +11 -13
  122. package/dist/cjs/management/api/resources/rules/client/Client.d.ts +4 -4
  123. package/dist/cjs/management/api/resources/rules/client/Client.js +4 -4
  124. package/dist/cjs/management/api/resources/userAttributeProfiles/client/Client.d.ts +1 -1
  125. package/dist/cjs/management/api/resources/userAttributeProfiles/client/Client.js +1 -1
  126. package/dist/cjs/management/api/resources/userBlocks/client/Client.d.ts +6 -6
  127. package/dist/cjs/management/api/resources/userBlocks/client/Client.js +6 -6
  128. package/dist/cjs/management/api/resources/users/client/Client.d.ts +82 -51
  129. package/dist/cjs/management/api/resources/users/client/Client.js +110 -75
  130. package/dist/cjs/management/api/resources/users/resources/authenticators/client/Client.d.ts +1 -1
  131. package/dist/cjs/management/api/resources/users/resources/authenticators/client/Client.js +1 -1
  132. package/dist/cjs/management/api/resources/users/resources/effectivePermissions/client/Client.d.ts +37 -0
  133. package/dist/cjs/management/api/resources/users/resources/effectivePermissions/client/Client.js +151 -0
  134. package/dist/cjs/management/api/resources/users/resources/effectivePermissions/client/index.d.ts +1 -0
  135. package/dist/cjs/management/api/resources/users/resources/effectivePermissions/client/index.js +2 -0
  136. package/dist/cjs/management/api/resources/users/resources/effectivePermissions/index.d.ts +2 -0
  137. package/dist/cjs/management/api/resources/users/resources/effectivePermissions/index.js +18 -0
  138. package/dist/cjs/management/api/resources/users/resources/effectivePermissions/resources/index.d.ts +1 -0
  139. package/dist/cjs/management/api/resources/users/resources/effectivePermissions/resources/index.js +37 -0
  140. package/dist/cjs/management/api/resources/users/resources/effectivePermissions/resources/sources/client/Client.d.ts +12 -0
  141. package/dist/cjs/management/api/resources/users/resources/effectivePermissions/resources/sources/client/Client.js +16 -0
  142. package/dist/cjs/management/api/resources/users/resources/effectivePermissions/resources/sources/client/index.d.ts +1 -0
  143. package/dist/cjs/management/api/resources/users/resources/effectivePermissions/resources/sources/client/index.js +2 -0
  144. package/dist/cjs/management/api/resources/users/resources/effectivePermissions/resources/sources/index.d.ts +2 -0
  145. package/dist/cjs/management/api/resources/users/resources/effectivePermissions/resources/sources/index.js +18 -0
  146. package/dist/cjs/management/api/resources/users/resources/effectivePermissions/resources/sources/resources/index.d.ts +1 -0
  147. package/dist/cjs/management/api/resources/users/resources/effectivePermissions/resources/sources/resources/index.js +37 -0
  148. package/dist/cjs/management/api/resources/users/resources/effectivePermissions/resources/sources/resources/roles/client/Client.d.ts +35 -0
  149. package/dist/cjs/management/api/resources/users/resources/effectivePermissions/resources/sources/resources/roles/client/Client.js +148 -0
  150. package/dist/cjs/management/api/resources/users/resources/effectivePermissions/resources/sources/resources/roles/client/index.d.ts +1 -0
  151. package/dist/cjs/management/api/resources/users/resources/effectivePermissions/resources/sources/resources/roles/client/index.js +2 -0
  152. package/dist/cjs/management/api/resources/users/resources/effectivePermissions/resources/sources/resources/roles/index.d.ts +1 -0
  153. package/dist/cjs/management/api/resources/users/resources/effectivePermissions/resources/sources/resources/roles/index.js +17 -0
  154. package/dist/cjs/management/api/resources/users/resources/effectiveRoles/client/Client.d.ts +35 -0
  155. package/dist/cjs/management/api/resources/users/resources/effectiveRoles/client/Client.js +146 -0
  156. package/dist/cjs/management/api/resources/users/resources/effectiveRoles/client/index.d.ts +1 -0
  157. package/dist/cjs/management/api/resources/users/resources/effectiveRoles/client/index.js +2 -0
  158. package/dist/cjs/management/api/resources/users/resources/effectiveRoles/index.d.ts +2 -0
  159. package/dist/cjs/management/api/resources/users/resources/effectiveRoles/index.js +18 -0
  160. package/dist/cjs/management/api/resources/users/resources/effectiveRoles/resources/index.d.ts +1 -0
  161. package/dist/cjs/management/api/resources/users/resources/effectiveRoles/resources/index.js +37 -0
  162. package/dist/cjs/management/api/resources/users/resources/effectiveRoles/resources/sources/client/Client.d.ts +12 -0
  163. package/dist/cjs/management/api/resources/users/resources/effectiveRoles/resources/sources/client/Client.js +16 -0
  164. package/dist/cjs/management/api/resources/users/resources/effectiveRoles/resources/sources/client/index.d.ts +1 -0
  165. package/dist/cjs/management/api/resources/users/resources/effectiveRoles/resources/sources/client/index.js +2 -0
  166. package/dist/cjs/management/api/resources/users/resources/effectiveRoles/resources/sources/index.d.ts +2 -0
  167. package/dist/cjs/management/api/resources/users/resources/effectiveRoles/resources/sources/index.js +18 -0
  168. package/dist/cjs/management/api/resources/users/resources/effectiveRoles/resources/sources/resources/groups/client/Client.d.ts +33 -0
  169. package/dist/cjs/management/api/resources/users/resources/effectiveRoles/resources/sources/resources/groups/client/Client.js +143 -0
  170. package/dist/cjs/management/api/resources/users/resources/effectiveRoles/resources/sources/resources/groups/client/index.d.ts +1 -0
  171. package/dist/cjs/management/api/resources/users/resources/effectiveRoles/resources/sources/resources/groups/client/index.js +2 -0
  172. package/dist/cjs/management/api/resources/users/resources/effectiveRoles/resources/sources/resources/groups/index.d.ts +1 -0
  173. package/dist/cjs/management/api/resources/users/resources/effectiveRoles/resources/sources/resources/groups/index.js +17 -0
  174. package/dist/cjs/management/api/resources/users/resources/effectiveRoles/resources/sources/resources/index.d.ts +1 -0
  175. package/dist/cjs/management/api/resources/users/resources/effectiveRoles/resources/sources/resources/index.js +37 -0
  176. package/dist/cjs/management/api/resources/users/resources/enrollments/client/Client.d.ts +1 -1
  177. package/dist/cjs/management/api/resources/users/resources/enrollments/client/Client.js +1 -1
  178. package/dist/cjs/management/api/resources/users/resources/identities/client/Client.d.ts +26 -25
  179. package/dist/cjs/management/api/resources/users/resources/identities/client/Client.js +26 -25
  180. package/dist/cjs/management/api/resources/users/resources/index.d.ts +2 -0
  181. package/dist/cjs/management/api/resources/users/resources/index.js +3 -1
  182. package/dist/cjs/management/api/resources/users/resources/multifactor/client/Client.d.ts +2 -2
  183. package/dist/cjs/management/api/resources/users/resources/multifactor/client/Client.js +2 -2
  184. package/dist/cjs/management/api/resources/users/resources/organizations/client/Client.d.ts +1 -1
  185. package/dist/cjs/management/api/resources/users/resources/organizations/client/Client.js +1 -1
  186. package/dist/cjs/management/api/resources/users/resources/roles/client/Client.d.ts +6 -4
  187. package/dist/cjs/management/api/resources/users/resources/roles/client/Client.js +10 -4
  188. package/dist/cjs/management/api/types/types.d.ts +503 -53
  189. package/dist/cjs/management/api/types/types.js +133 -14
  190. package/dist/cjs/management/core/auth/AuthProvider.d.ts +1 -0
  191. package/dist/cjs/management/core/auth/AuthProvider.js +7 -0
  192. package/dist/cjs/management/core/auth/index.d.ts +1 -1
  193. package/dist/cjs/management/core/auth/index.js +3 -1
  194. package/dist/cjs/management/core/fetcher/requestWithRetries.js +4 -1
  195. package/dist/cjs/management/version.d.ts +1 -1
  196. package/dist/cjs/management/version.js +1 -1
  197. package/dist/esm/management/BaseClient.d.mts +3 -0
  198. package/dist/esm/management/BaseClient.mjs +15 -0
  199. package/dist/esm/management/Client.d.mts +3 -0
  200. package/dist/esm/management/Client.mjs +5 -0
  201. package/dist/esm/management/api/requests/requests.d.mts +281 -3
  202. package/dist/esm/management/api/resources/actions/client/Client.d.mts +1 -1
  203. package/dist/esm/management/api/resources/actions/client/Client.mjs +1 -1
  204. package/dist/esm/management/api/resources/branding/resources/templates/client/Client.d.mts +16 -16
  205. package/dist/esm/management/api/resources/branding/resources/templates/client/Client.mjs +16 -16
  206. package/dist/esm/management/api/resources/clients/client/Client.d.mts +12 -3
  207. package/dist/esm/management/api/resources/clients/client/Client.mjs +12 -3
  208. package/dist/esm/management/api/resources/connections/client/Client.d.mts +17 -19
  209. package/dist/esm/management/api/resources/connections/client/Client.mjs +17 -19
  210. package/dist/esm/management/api/resources/connections/resources/clients/client/Client.d.mts +2 -2
  211. package/dist/esm/management/api/resources/connections/resources/clients/client/Client.mjs +2 -2
  212. package/dist/esm/management/api/resources/connections/resources/scimConfiguration/client/Client.d.mts +4 -4
  213. package/dist/esm/management/api/resources/connections/resources/scimConfiguration/client/Client.mjs +4 -4
  214. package/dist/esm/management/api/resources/connections/resources/scimConfiguration/resources/tokens/client/Client.d.mts +2 -2
  215. package/dist/esm/management/api/resources/connections/resources/scimConfiguration/resources/tokens/client/Client.mjs +2 -2
  216. package/dist/esm/management/api/resources/customDomains/client/Client.d.mts +19 -12
  217. package/dist/esm/management/api/resources/customDomains/client/Client.mjs +19 -12
  218. package/dist/esm/management/api/resources/deviceCredentials/client/Client.d.mts +3 -3
  219. package/dist/esm/management/api/resources/deviceCredentials/client/Client.mjs +3 -3
  220. package/dist/esm/management/api/resources/groups/client/Client.d.mts +3 -0
  221. package/dist/esm/management/api/resources/groups/client/Client.mjs +5 -0
  222. package/dist/esm/management/api/resources/groups/resources/index.d.mts +1 -0
  223. package/dist/esm/management/api/resources/groups/resources/index.mjs +1 -0
  224. package/dist/esm/management/api/resources/groups/resources/roles/client/Client.d.mts +71 -0
  225. package/dist/esm/management/api/resources/groups/resources/roles/client/Client.mjs +233 -0
  226. package/dist/esm/management/api/resources/groups/resources/roles/client/index.d.mts +1 -0
  227. package/dist/esm/management/api/resources/groups/resources/roles/client/index.mjs +1 -0
  228. package/dist/esm/management/api/resources/groups/resources/roles/index.d.mts +1 -0
  229. package/dist/esm/management/api/resources/groups/resources/roles/index.mjs +1 -0
  230. package/dist/esm/management/api/resources/guardian/resources/enrollments/client/Client.d.mts +2 -5
  231. package/dist/esm/management/api/resources/guardian/resources/enrollments/client/Client.mjs +2 -5
  232. package/dist/esm/management/api/resources/guardian/resources/factors/resources/pushNotification/client/Client.d.mts +3 -3
  233. package/dist/esm/management/api/resources/guardian/resources/factors/resources/pushNotification/client/Client.mjs +3 -3
  234. package/dist/esm/management/api/resources/guardian/resources/policies/client/Client.d.mts +10 -12
  235. package/dist/esm/management/api/resources/guardian/resources/policies/client/Client.mjs +10 -12
  236. package/dist/esm/management/api/resources/hooks/client/Client.d.mts +2 -2
  237. package/dist/esm/management/api/resources/hooks/client/Client.mjs +2 -2
  238. package/dist/esm/management/api/resources/index.d.mts +1 -0
  239. package/dist/esm/management/api/resources/index.mjs +1 -0
  240. package/dist/esm/management/api/resources/jobs/resources/verificationEmail/client/Client.d.mts +1 -1
  241. package/dist/esm/management/api/resources/jobs/resources/verificationEmail/client/Client.mjs +1 -1
  242. package/dist/esm/management/api/resources/logs/client/Client.d.mts +17 -20
  243. package/dist/esm/management/api/resources/logs/client/Client.mjs +17 -20
  244. package/dist/esm/management/api/resources/organizations/client/Client.d.mts +14 -13
  245. package/dist/esm/management/api/resources/organizations/client/Client.mjs +16 -13
  246. package/dist/esm/management/api/resources/organizations/resources/discoveryDomains/client/Client.d.mts +1 -1
  247. package/dist/esm/management/api/resources/organizations/resources/discoveryDomains/client/Client.mjs +1 -1
  248. package/dist/esm/management/api/resources/organizations/resources/enabledConnections/client/Client.d.mts +2 -2
  249. package/dist/esm/management/api/resources/organizations/resources/enabledConnections/client/Client.mjs +2 -2
  250. package/dist/esm/management/api/resources/organizations/resources/groups/client/Client.d.mts +35 -0
  251. package/dist/esm/management/api/resources/organizations/resources/groups/client/Client.mjs +109 -0
  252. package/dist/esm/management/api/resources/organizations/resources/groups/client/index.d.mts +1 -0
  253. package/dist/esm/management/api/resources/organizations/resources/groups/client/index.mjs +1 -0
  254. package/dist/esm/management/api/resources/organizations/resources/groups/index.d.mts +2 -0
  255. package/dist/esm/management/api/resources/organizations/resources/groups/index.mjs +2 -0
  256. package/dist/esm/management/api/resources/organizations/resources/groups/resources/index.d.mts +1 -0
  257. package/dist/esm/management/api/resources/organizations/resources/groups/resources/index.mjs +1 -0
  258. package/dist/esm/management/api/resources/organizations/resources/groups/resources/roles/client/Client.d.mts +74 -0
  259. package/dist/esm/management/api/resources/organizations/resources/groups/resources/roles/client/Client.mjs +236 -0
  260. package/dist/esm/management/api/resources/organizations/resources/groups/resources/roles/client/index.d.mts +1 -0
  261. package/dist/esm/management/api/resources/organizations/resources/groups/resources/roles/client/index.mjs +1 -0
  262. package/dist/esm/management/api/resources/organizations/resources/groups/resources/roles/index.d.mts +1 -0
  263. package/dist/esm/management/api/resources/organizations/resources/groups/resources/roles/index.mjs +1 -0
  264. package/dist/esm/management/api/resources/organizations/resources/index.d.mts +1 -0
  265. package/dist/esm/management/api/resources/organizations/resources/index.mjs +1 -0
  266. package/dist/esm/management/api/resources/organizations/resources/invitations/client/Client.d.mts +2 -2
  267. package/dist/esm/management/api/resources/organizations/resources/invitations/client/Client.mjs +2 -2
  268. package/dist/esm/management/api/resources/organizations/resources/members/client/Client.d.mts +9 -12
  269. package/dist/esm/management/api/resources/organizations/resources/members/client/Client.mjs +11 -12
  270. package/dist/esm/management/api/resources/organizations/resources/members/resources/effectiveRoles/client/Client.d.mts +36 -0
  271. package/dist/esm/management/api/resources/organizations/resources/members/resources/effectiveRoles/client/Client.mjs +110 -0
  272. package/dist/esm/management/api/resources/organizations/resources/members/resources/effectiveRoles/client/index.d.mts +1 -0
  273. package/dist/esm/management/api/resources/organizations/resources/members/resources/effectiveRoles/client/index.mjs +1 -0
  274. package/dist/esm/management/api/resources/organizations/resources/members/resources/effectiveRoles/index.d.mts +2 -0
  275. package/dist/esm/management/api/resources/organizations/resources/members/resources/effectiveRoles/index.mjs +2 -0
  276. package/dist/esm/management/api/resources/organizations/resources/members/resources/effectiveRoles/resources/index.d.mts +1 -0
  277. package/dist/esm/management/api/resources/organizations/resources/members/resources/effectiveRoles/resources/index.mjs +1 -0
  278. package/dist/esm/management/api/resources/organizations/resources/members/resources/effectiveRoles/resources/sources/client/Client.d.mts +12 -0
  279. package/dist/esm/management/api/resources/organizations/resources/members/resources/effectiveRoles/resources/sources/client/Client.mjs +12 -0
  280. package/dist/esm/management/api/resources/organizations/resources/members/resources/effectiveRoles/resources/sources/client/index.d.mts +1 -0
  281. package/dist/esm/management/api/resources/organizations/resources/members/resources/effectiveRoles/resources/sources/client/index.mjs +1 -0
  282. package/dist/esm/management/api/resources/organizations/resources/members/resources/effectiveRoles/resources/sources/index.d.mts +2 -0
  283. package/dist/esm/management/api/resources/organizations/resources/members/resources/effectiveRoles/resources/sources/index.mjs +2 -0
  284. package/dist/esm/management/api/resources/organizations/resources/members/resources/effectiveRoles/resources/sources/resources/groups/client/Client.d.mts +34 -0
  285. package/dist/esm/management/api/resources/organizations/resources/members/resources/effectiveRoles/resources/sources/resources/groups/client/Client.mjs +107 -0
  286. package/dist/esm/management/api/resources/organizations/resources/members/resources/effectiveRoles/resources/sources/resources/groups/client/index.d.mts +1 -0
  287. package/dist/esm/management/api/resources/organizations/resources/members/resources/effectiveRoles/resources/sources/resources/groups/client/index.mjs +1 -0
  288. package/dist/esm/management/api/resources/organizations/resources/members/resources/effectiveRoles/resources/sources/resources/groups/index.d.mts +1 -0
  289. package/dist/esm/management/api/resources/organizations/resources/members/resources/effectiveRoles/resources/sources/resources/groups/index.mjs +1 -0
  290. package/dist/esm/management/api/resources/organizations/resources/members/resources/effectiveRoles/resources/sources/resources/index.d.mts +1 -0
  291. package/dist/esm/management/api/resources/organizations/resources/members/resources/effectiveRoles/resources/sources/resources/index.mjs +1 -0
  292. package/dist/esm/management/api/resources/organizations/resources/members/resources/index.d.mts +1 -0
  293. package/dist/esm/management/api/resources/organizations/resources/members/resources/index.mjs +1 -0
  294. package/dist/esm/management/api/resources/organizations/resources/members/resources/roles/client/Client.d.mts +2 -2
  295. package/dist/esm/management/api/resources/organizations/resources/members/resources/roles/client/Client.mjs +2 -2
  296. package/dist/esm/management/api/resources/prompts/resources/rendering/client/Client.d.mts +2 -2
  297. package/dist/esm/management/api/resources/prompts/resources/rendering/client/Client.mjs +2 -2
  298. package/dist/esm/management/api/resources/rateLimitPolicies/client/Client.d.mts +102 -0
  299. package/dist/esm/management/api/resources/rateLimitPolicies/client/Client.mjs +360 -0
  300. package/dist/esm/management/api/resources/rateLimitPolicies/client/index.d.mts +1 -0
  301. package/dist/esm/management/api/resources/rateLimitPolicies/client/index.mjs +1 -0
  302. package/dist/esm/management/api/resources/rateLimitPolicies/index.d.mts +1 -0
  303. package/dist/esm/management/api/resources/rateLimitPolicies/index.mjs +1 -0
  304. package/dist/esm/management/api/resources/roles/client/Client.d.mts +9 -6
  305. package/dist/esm/management/api/resources/roles/client/Client.mjs +11 -6
  306. package/dist/esm/management/api/resources/roles/resources/groups/client/Client.d.mts +71 -0
  307. package/dist/esm/management/api/resources/roles/resources/groups/client/Client.mjs +233 -0
  308. package/dist/esm/management/api/resources/roles/resources/groups/client/index.d.mts +1 -0
  309. package/dist/esm/management/api/resources/roles/resources/groups/client/index.mjs +1 -0
  310. package/dist/esm/management/api/resources/roles/resources/groups/index.d.mts +1 -0
  311. package/dist/esm/management/api/resources/roles/resources/groups/index.mjs +1 -0
  312. package/dist/esm/management/api/resources/roles/resources/index.d.mts +1 -0
  313. package/dist/esm/management/api/resources/roles/resources/index.mjs +1 -0
  314. package/dist/esm/management/api/resources/roles/resources/permissions/client/Client.d.mts +2 -2
  315. package/dist/esm/management/api/resources/roles/resources/permissions/client/Client.mjs +2 -2
  316. package/dist/esm/management/api/resources/roles/resources/users/client/Client.d.mts +11 -13
  317. package/dist/esm/management/api/resources/roles/resources/users/client/Client.mjs +11 -13
  318. package/dist/esm/management/api/resources/rules/client/Client.d.mts +4 -4
  319. package/dist/esm/management/api/resources/rules/client/Client.mjs +4 -4
  320. package/dist/esm/management/api/resources/userAttributeProfiles/client/Client.d.mts +1 -1
  321. package/dist/esm/management/api/resources/userAttributeProfiles/client/Client.mjs +1 -1
  322. package/dist/esm/management/api/resources/userBlocks/client/Client.d.mts +6 -6
  323. package/dist/esm/management/api/resources/userBlocks/client/Client.mjs +6 -6
  324. package/dist/esm/management/api/resources/users/client/Client.d.mts +82 -51
  325. package/dist/esm/management/api/resources/users/client/Client.mjs +86 -51
  326. package/dist/esm/management/api/resources/users/resources/authenticators/client/Client.d.mts +1 -1
  327. package/dist/esm/management/api/resources/users/resources/authenticators/client/Client.mjs +1 -1
  328. package/dist/esm/management/api/resources/users/resources/effectivePermissions/client/Client.d.mts +37 -0
  329. package/dist/esm/management/api/resources/users/resources/effectivePermissions/client/Client.mjs +114 -0
  330. package/dist/esm/management/api/resources/users/resources/effectivePermissions/client/index.d.mts +1 -0
  331. package/dist/esm/management/api/resources/users/resources/effectivePermissions/client/index.mjs +1 -0
  332. package/dist/esm/management/api/resources/users/resources/effectivePermissions/index.d.mts +2 -0
  333. package/dist/esm/management/api/resources/users/resources/effectivePermissions/index.mjs +2 -0
  334. package/dist/esm/management/api/resources/users/resources/effectivePermissions/resources/index.d.mts +1 -0
  335. package/dist/esm/management/api/resources/users/resources/effectivePermissions/resources/index.mjs +1 -0
  336. package/dist/esm/management/api/resources/users/resources/effectivePermissions/resources/sources/client/Client.d.mts +12 -0
  337. package/dist/esm/management/api/resources/users/resources/effectivePermissions/resources/sources/client/Client.mjs +12 -0
  338. package/dist/esm/management/api/resources/users/resources/effectivePermissions/resources/sources/client/index.d.mts +1 -0
  339. package/dist/esm/management/api/resources/users/resources/effectivePermissions/resources/sources/client/index.mjs +1 -0
  340. package/dist/esm/management/api/resources/users/resources/effectivePermissions/resources/sources/index.d.mts +2 -0
  341. package/dist/esm/management/api/resources/users/resources/effectivePermissions/resources/sources/index.mjs +2 -0
  342. package/dist/esm/management/api/resources/users/resources/effectivePermissions/resources/sources/resources/index.d.mts +1 -0
  343. package/dist/esm/management/api/resources/users/resources/effectivePermissions/resources/sources/resources/index.mjs +1 -0
  344. package/dist/esm/management/api/resources/users/resources/effectivePermissions/resources/sources/resources/roles/client/Client.d.mts +35 -0
  345. package/dist/esm/management/api/resources/users/resources/effectivePermissions/resources/sources/resources/roles/client/Client.mjs +111 -0
  346. package/dist/esm/management/api/resources/users/resources/effectivePermissions/resources/sources/resources/roles/client/index.d.mts +1 -0
  347. package/dist/esm/management/api/resources/users/resources/effectivePermissions/resources/sources/resources/roles/client/index.mjs +1 -0
  348. package/dist/esm/management/api/resources/users/resources/effectivePermissions/resources/sources/resources/roles/index.d.mts +1 -0
  349. package/dist/esm/management/api/resources/users/resources/effectivePermissions/resources/sources/resources/roles/index.mjs +1 -0
  350. package/dist/esm/management/api/resources/users/resources/effectiveRoles/client/Client.d.mts +35 -0
  351. package/dist/esm/management/api/resources/users/resources/effectiveRoles/client/Client.mjs +109 -0
  352. package/dist/esm/management/api/resources/users/resources/effectiveRoles/client/index.d.mts +1 -0
  353. package/dist/esm/management/api/resources/users/resources/effectiveRoles/client/index.mjs +1 -0
  354. package/dist/esm/management/api/resources/users/resources/effectiveRoles/index.d.mts +2 -0
  355. package/dist/esm/management/api/resources/users/resources/effectiveRoles/index.mjs +2 -0
  356. package/dist/esm/management/api/resources/users/resources/effectiveRoles/resources/index.d.mts +1 -0
  357. package/dist/esm/management/api/resources/users/resources/effectiveRoles/resources/index.mjs +1 -0
  358. package/dist/esm/management/api/resources/users/resources/effectiveRoles/resources/sources/client/Client.d.mts +12 -0
  359. package/dist/esm/management/api/resources/users/resources/effectiveRoles/resources/sources/client/Client.mjs +12 -0
  360. package/dist/esm/management/api/resources/users/resources/effectiveRoles/resources/sources/client/index.d.mts +1 -0
  361. package/dist/esm/management/api/resources/users/resources/effectiveRoles/resources/sources/client/index.mjs +1 -0
  362. package/dist/esm/management/api/resources/users/resources/effectiveRoles/resources/sources/index.d.mts +2 -0
  363. package/dist/esm/management/api/resources/users/resources/effectiveRoles/resources/sources/index.mjs +2 -0
  364. package/dist/esm/management/api/resources/users/resources/effectiveRoles/resources/sources/resources/groups/client/Client.d.mts +33 -0
  365. package/dist/esm/management/api/resources/users/resources/effectiveRoles/resources/sources/resources/groups/client/Client.mjs +106 -0
  366. package/dist/esm/management/api/resources/users/resources/effectiveRoles/resources/sources/resources/groups/client/index.d.mts +1 -0
  367. package/dist/esm/management/api/resources/users/resources/effectiveRoles/resources/sources/resources/groups/client/index.mjs +1 -0
  368. package/dist/esm/management/api/resources/users/resources/effectiveRoles/resources/sources/resources/groups/index.d.mts +1 -0
  369. package/dist/esm/management/api/resources/users/resources/effectiveRoles/resources/sources/resources/groups/index.mjs +1 -0
  370. package/dist/esm/management/api/resources/users/resources/effectiveRoles/resources/sources/resources/index.d.mts +1 -0
  371. package/dist/esm/management/api/resources/users/resources/effectiveRoles/resources/sources/resources/index.mjs +1 -0
  372. package/dist/esm/management/api/resources/users/resources/enrollments/client/Client.d.mts +1 -1
  373. package/dist/esm/management/api/resources/users/resources/enrollments/client/Client.mjs +1 -1
  374. package/dist/esm/management/api/resources/users/resources/identities/client/Client.d.mts +26 -25
  375. package/dist/esm/management/api/resources/users/resources/identities/client/Client.mjs +26 -25
  376. package/dist/esm/management/api/resources/users/resources/index.d.mts +2 -0
  377. package/dist/esm/management/api/resources/users/resources/index.mjs +2 -0
  378. package/dist/esm/management/api/resources/users/resources/multifactor/client/Client.d.mts +2 -2
  379. package/dist/esm/management/api/resources/users/resources/multifactor/client/Client.mjs +2 -2
  380. package/dist/esm/management/api/resources/users/resources/organizations/client/Client.d.mts +1 -1
  381. package/dist/esm/management/api/resources/users/resources/organizations/client/Client.mjs +1 -1
  382. package/dist/esm/management/api/resources/users/resources/roles/client/Client.d.mts +6 -4
  383. package/dist/esm/management/api/resources/users/resources/roles/client/Client.mjs +10 -4
  384. package/dist/esm/management/api/types/types.d.mts +503 -53
  385. package/dist/esm/management/api/types/types.mjs +120 -1
  386. package/dist/esm/management/core/auth/AuthProvider.d.mts +1 -0
  387. package/dist/esm/management/core/auth/AuthProvider.mjs +6 -1
  388. package/dist/esm/management/core/auth/index.d.mts +1 -1
  389. package/dist/esm/management/core/auth/index.mjs +1 -0
  390. package/dist/esm/management/core/fetcher/requestWithRetries.mjs +4 -1
  391. package/dist/esm/management/version.d.mts +1 -1
  392. package/dist/esm/management/version.mjs +1 -1
  393. package/package.json +3 -3
  394. package/reference.md +3564 -1868
@@ -5,6 +5,8 @@ import * as Management from "../../../index.mjs";
5
5
  import { AuthenticationMethodsClient } from "../resources/authenticationMethods/client/Client.mjs";
6
6
  import { AuthenticatorsClient } from "../resources/authenticators/client/Client.mjs";
7
7
  import { ConnectedAccountsClient } from "../resources/connectedAccounts/client/Client.mjs";
8
+ import { EffectivePermissionsClient } from "../resources/effectivePermissions/client/Client.mjs";
9
+ import { EffectiveRolesClient } from "../resources/effectiveRoles/client/Client.mjs";
8
10
  import { EnrollmentsClient } from "../resources/enrollments/client/Client.mjs";
9
11
  import { FederatedConnectionsTokensetsClient } from "../resources/federatedConnectionsTokensets/client/Client.mjs";
10
12
  import { GroupsClient } from "../resources/groups/client/Client.mjs";
@@ -27,6 +29,8 @@ export declare class UsersClient {
27
29
  protected _authenticationMethods: AuthenticationMethodsClient | undefined;
28
30
  protected _authenticators: AuthenticatorsClient | undefined;
29
31
  protected _connectedAccounts: ConnectedAccountsClient | undefined;
32
+ protected _effectivePermissions: EffectivePermissionsClient | undefined;
33
+ protected _effectiveRoles: EffectiveRolesClient | undefined;
30
34
  protected _enrollments: EnrollmentsClient | undefined;
31
35
  protected _federatedConnectionsTokensets: FederatedConnectionsTokensetsClient | undefined;
32
36
  protected _groups: GroupsClient | undefined;
@@ -43,6 +47,8 @@ export declare class UsersClient {
43
47
  get authenticationMethods(): AuthenticationMethodsClient;
44
48
  get authenticators(): AuthenticatorsClient;
45
49
  get connectedAccounts(): ConnectedAccountsClient;
50
+ get effectivePermissions(): EffectivePermissionsClient;
51
+ get effectiveRoles(): EffectiveRolesClient;
46
52
  get enrollments(): EnrollmentsClient;
47
53
  get federatedConnectionsTokensets(): FederatedConnectionsTokensetsClient;
48
54
  get groups(): GroupsClient;
@@ -62,14 +68,18 @@ export declare class UsersClient {
62
68
  * - Sort the users to be returned
63
69
  * - Select the fields to be returned
64
70
  * - Specify the number of users to retrieve per page and the page index
65
- * <!-- only v3 is available -->
66
- * The <code>q</code> query parameter can be used to get users that match the specified criteria <a href="https://auth0.com/docs/users/search/v3/query-syntax">using query string syntax.</a>
67
71
  *
68
- * <a href="https://auth0.com/docs/users/search/v3">Learn more about searching for users.</a>
69
72
  *
70
- * Read about <a href="https://auth0.com/docs/users/search/best-practices">best practices</a> when working with the API endpoints for retrieving users.
71
73
  *
72
- * Auth0 limits the number of users you can return. If you exceed this threshold, please redefine your search, use the <a href="https://auth0.com/docs/api/management/v2#!/Jobs/post_users_exports">export job</a>, or the <a href="https://auth0.com/docs/extensions/user-import-export">User Import / Export</a> extension.
74
+ * The `q` query parameter can be used to get users that match the specified criteria [using query string syntax.](https://auth0.com/docs/users/search/v3/query-syntax)
75
+ *
76
+ * [Learn more about searching for users.](https://auth0.com/docs/users/search/v3)
77
+ *
78
+ * Read about [best practices](https://auth0.com/docs/users/search/best-practices) when working with the API endpoints for retrieving users.
79
+ *
80
+ *
81
+ *
82
+ * Auth0 limits the number of users you can return. If you exceed this threshold, please redefine your search, use the [export job](https://auth0.com/docs/api/management/v2#!/Jobs/post_users_exports), or the [User Import / Export](https://auth0.com/docs/extensions/user-import-export) extension.
73
83
  *
74
84
  * @param {Management.ListUsersRequestParameters} request
75
85
  * @param {UsersClient.RequestOptions} requestOptions - Request-specific configuration.
@@ -96,9 +106,9 @@ export declare class UsersClient {
96
106
  */
97
107
  list(request?: Management.ListUsersRequestParameters, requestOptions?: UsersClient.RequestOptions): Promise<core.Page<Management.UserResponseSchema, Management.ListUsersOffsetPaginatedResponseContent>>;
98
108
  /**
99
- * Create a new user for a given <a href="https://auth0.com/docs/connections/database">database</a> or <a href="https://auth0.com/docs/connections/passwordless">passwordless</a> connection.
109
+ * Create a new user for a given [database](https://auth0.com/docs/connections/database) or [passwordless](https://auth0.com/docs/connections/passwordless) connection.
100
110
  *
101
- * Note: <code>connection</code> is required but other parameters such as <code>email</code> and <code>password</code> are dependent upon the type of connection.
111
+ * Note: `connection` is required but other parameters such as `email` and `password` are dependent upon the type of connection.
102
112
  *
103
113
  * @param {Management.CreateUserRequestContent} request
104
114
  * @param {UsersClient.RequestOptions} requestOptions - Request-specific configuration.
@@ -141,7 +151,7 @@ export declare class UsersClient {
141
151
  listUsersByEmail(request: Management.ListUsersByEmailRequestParameters, requestOptions?: UsersClient.RequestOptions): core.HttpResponsePromise<Management.UserResponseSchema[]>;
142
152
  private __listUsersByEmail;
143
153
  /**
144
- * Retrieve user details. A list of fields to include or exclude may also be specified. For more information, see <a href="https://auth0.com/docs/manage-users/user-search/retrieve-users-with-get-users-endpoint">Retrieve Users with the Get Users Endpoint</a>.
154
+ * Retrieve user details. A list of fields to include or exclude may also be specified. For more information, see [Retrieve Users with the Get Users Endpoint](https://auth0.com/docs/manage-users/user-search/retrieve-users-with-get-users-endpoint).
145
155
  *
146
156
  * @param {string} id - ID of the user to retrieve.
147
157
  * @param {Management.GetUserRequestParameters} request
@@ -162,7 +172,7 @@ export declare class UsersClient {
162
172
  get(id: string, request?: Management.GetUserRequestParameters, requestOptions?: UsersClient.RequestOptions): core.HttpResponsePromise<Management.GetUserResponseContent>;
163
173
  private __get;
164
174
  /**
165
- * Delete a user by user ID. This action cannot be undone. For Auth0 Dashboard instructions, see <a href="https://auth0.com/docs/manage-users/user-accounts/delete-users">Delete Users</a>.
175
+ * Delete a user by user ID. This action cannot be undone. For Auth0 Dashboard instructions, see [Delete Users](https://auth0.com/docs/manage-users/user-accounts/delete-users).
166
176
  *
167
177
  * @param {string} id - ID of the user to delete.
168
178
  * @param {UsersClient.RequestOptions} requestOptions - Request-specific configuration.
@@ -182,64 +192,84 @@ export declare class UsersClient {
182
192
  *
183
193
  * These are the attributes that can be updated at the root level:
184
194
  *
185
- * <ul>
186
- * <li>app_metadata</li>
187
- * <li>blocked</li>
188
- * <li>email</li>
189
- * <li>email_verified</li>
190
- * <li>family_name</li>
191
- * <li>given_name</li>
192
- * <li>name</li>
193
- * <li>nickname</li>
194
- * <li>password</li>
195
- * <li>phone_number</li>
196
- * <li>phone_verified</li>
197
- * <li>picture</li>
198
- * <li>username</li>
199
- * <li>user_metadata</li>
200
- * <li>verify_email</li>
201
- * </ul>
195
+ * - app_metadata
196
+ * - blocked
197
+ * - email
198
+ * - email_verified
199
+ * - family_name
200
+ * - given_name
201
+ * - name
202
+ * - nickname
203
+ * - password
204
+ * - phone_number
205
+ * - phone_verified
206
+ * - picture
207
+ * - username
208
+ * - user_metadata
209
+ * - verify_email
202
210
  *
203
211
  * Some considerations:
204
- * <ul>
205
- * <li>The properties of the new object will replace the old ones.</li>
206
- * <li>The metadata fields are an exception to this rule (<code>user_metadata</code> and <code>app_metadata</code>). These properties are merged instead of being replaced but be careful, the merge only occurs on the first level.</li>
207
- * <li>If you are updating <code>email</code>, <code>email_verified</code>, <code>phone_number</code>, <code>phone_verified</code>, <code>username</code> or <code>password</code> of a secondary identity, you need to specify the <code>connection</code> property too.</li>
208
- * <li>If you are updating <code>email</code> or <code>phone_number</code> you can specify, optionally, the <code>client_id</code> property.</li>
209
- * <li>Updating <code>email_verified</code> is not supported for enterprise and passwordless sms connections.</li>
210
- * <li>Updating the <code>blocked</code> to <code>false</code> does not affect the user's blocked state from an excessive amount of incorrectly provided credentials. Use the "Unblock a user" endpoint from the "User Blocks" API to change the user's state.</li>
211
- * <li>Supported attributes can be unset by supplying <code>null</code> as the value.</li>
212
- * </ul>
213
- *
214
- * <h5>Updating a field (non-metadata property)</h5>
212
+ *
213
+ * - The properties of the new object will replace the old ones.
214
+ * - The metadata fields are an exception to this rule (`user_metadata` and `app_metadata`). These properties are merged instead of being replaced but be careful, the merge only occurs on the first level.
215
+ * - If you are updating `email`, `email_verified`, `phone_number`, `phone_verified`, `username` or `password` of a secondary identity, you need to specify the `connection` property too.
216
+ * - If you are updating `email` or `phone_number` you can specify, optionally, the `client_id` property.
217
+ * - Updating `email_verified` is not supported for enterprise and passwordless sms connections.
218
+ * - Updating the `blocked` to `false` does not affect the user's blocked state from an excessive amount of incorrectly provided credentials. Use the "Unblock a user" endpoint from the "User Blocks" API to change the user's state.
219
+ * - Supported attributes can be unset by supplying `null` as the value.
220
+ *
221
+ * **Updating a field (non-metadata property)**
222
+ *
215
223
  * To mark the email address of a user as verified, the body to send should be:
216
- * <pre><code>{ "email_verified": true }</code></pre>
217
224
  *
218
- * <h5>Updating a user metadata root property</h5>Let's assume that our test user has the following <code>user_metadata</code>:
219
- * <pre><code>{ "user_metadata" : { "profileCode": 1479 } }</code></pre>
225
+ * ```json
226
+ * { "email_verified": true }
227
+ * ```
220
228
  *
221
- * To add the field <code>addresses</code> the body to send should be:
222
- * <pre><code>{ "user_metadata" : { "addresses": {"work_address": "100 Industrial Way"} }}</code></pre>
229
+ * **Updating a user metadata root property**
223
230
  *
224
- * The modified object ends up with the following <code>user_metadata</code> property:<pre><code>{
231
+ * Let's assume that our test user has the following `user_metadata`:
232
+ *
233
+ * ```json
234
+ * { "user_metadata" : { "profileCode": 1479 } }
235
+ * ```
236
+ *
237
+ * To add the field `addresses` the body to send should be:
238
+ *
239
+ * ```json
240
+ * { "user_metadata" : { "addresses": {"work_address": "100 Industrial Way"} }}
241
+ * ```
242
+ *
243
+ * The modified object ends up with the following `user_metadata` property:
244
+ *
245
+ * ```json
246
+ * {
225
247
  * "user_metadata": {
226
248
  * "profileCode": 1479,
227
249
  * "addresses": { "work_address": "100 Industrial Way" }
228
250
  * }
229
- * }</code></pre>
251
+ * }
252
+ * ```
253
+ *
254
+ * **Updating an inner user metadata property**
230
255
  *
231
- * <h5>Updating an inner user metadata property</h5>If there's existing user metadata to which we want to add <code>"home_address": "742 Evergreen Terrace"</code> (using the <code>addresses</code> property) we should send the whole <code>addresses</code> object. Since this is a first-level object, the object will be merged in, but its own properties will not be. The body to send should be:
232
- * <pre><code>{
256
+ * If there's existing user metadata to which we want to add `"home_address": "742 Evergreen Terrace"` (using the `addresses` property) we should send the whole `addresses` object. Since this is a first-level object, the object will be merged in, but its own properties will not be. The body to send should be:
257
+ *
258
+ * ```json
259
+ * {
233
260
  * "user_metadata": {
234
261
  * "addresses": {
235
262
  * "work_address": "100 Industrial Way",
236
263
  * "home_address": "742 Evergreen Terrace"
237
264
  * }
238
265
  * }
239
- * }</code></pre>
266
+ * }
267
+ * ```
268
+ *
269
+ * The modified object ends up with the following `user_metadata` property:
240
270
  *
241
- * The modified object ends up with the following <code>user_metadata</code> property:
242
- * <pre><code>{
271
+ * ```json
272
+ * {
243
273
  * "user_metadata": {
244
274
  * "profileCode": 1479,
245
275
  * "addresses": {
@@ -247,7 +277,8 @@ export declare class UsersClient {
247
277
  * "home_address": "742 Evergreen Terrace"
248
278
  * }
249
279
  * }
250
- * }</code></pre>
280
+ * }
281
+ * ```
251
282
  *
252
283
  * @param {string} id - ID of the user to update.
253
284
  * @param {Management.UpdateUserRequestContent} request
@@ -265,7 +296,7 @@ export declare class UsersClient {
265
296
  update(id: string, request?: Management.UpdateUserRequestContent, requestOptions?: UsersClient.RequestOptions): core.HttpResponsePromise<Management.UpdateUserResponseContent>;
266
297
  private __update;
267
298
  /**
268
- * Remove an existing multi-factor authentication (MFA) <a href="https://auth0.com/docs/secure/multi-factor-authentication/reset-user-mfa">recovery code</a> and generate a new one. If a user cannot access the original device or account used for MFA enrollment, they can use a recovery code to authenticate.
299
+ * Remove an existing multi-factor authentication (MFA) [recovery code](https://auth0.com/docs/secure/multi-factor-authentication/reset-user-mfa) and generate a new one. If a user cannot access the original device or account used for MFA enrollment, they can use a recovery code to authenticate.
269
300
  *
270
301
  * @param {string} id - ID of the user to regenerate a multi-factor authentication recovery code for.
271
302
  * @param {UsersClient.RequestOptions} requestOptions - Request-specific configuration.
@@ -18,6 +18,8 @@ import * as Management from "../../../index.mjs";
18
18
  import { AuthenticationMethodsClient } from "../resources/authenticationMethods/client/Client.mjs";
19
19
  import { AuthenticatorsClient } from "../resources/authenticators/client/Client.mjs";
20
20
  import { ConnectedAccountsClient } from "../resources/connectedAccounts/client/Client.mjs";
21
+ import { EffectivePermissionsClient } from "../resources/effectivePermissions/client/Client.mjs";
22
+ import { EffectiveRolesClient } from "../resources/effectiveRoles/client/Client.mjs";
21
23
  import { EnrollmentsClient } from "../resources/enrollments/client/Client.mjs";
22
24
  import { FederatedConnectionsTokensetsClient } from "../resources/federatedConnectionsTokensets/client/Client.mjs";
23
25
  import { GroupsClient } from "../resources/groups/client/Client.mjs";
@@ -46,6 +48,14 @@ export class UsersClient {
46
48
  var _a;
47
49
  return ((_a = this._connectedAccounts) !== null && _a !== void 0 ? _a : (this._connectedAccounts = new ConnectedAccountsClient(this._options)));
48
50
  }
51
+ get effectivePermissions() {
52
+ var _a;
53
+ return ((_a = this._effectivePermissions) !== null && _a !== void 0 ? _a : (this._effectivePermissions = new EffectivePermissionsClient(this._options)));
54
+ }
55
+ get effectiveRoles() {
56
+ var _a;
57
+ return ((_a = this._effectiveRoles) !== null && _a !== void 0 ? _a : (this._effectiveRoles = new EffectiveRolesClient(this._options)));
58
+ }
49
59
  get enrollments() {
50
60
  var _a;
51
61
  return ((_a = this._enrollments) !== null && _a !== void 0 ? _a : (this._enrollments = new EnrollmentsClient(this._options)));
@@ -101,14 +111,18 @@ export class UsersClient {
101
111
  * - Sort the users to be returned
102
112
  * - Select the fields to be returned
103
113
  * - Specify the number of users to retrieve per page and the page index
104
- * <!-- only v3 is available -->
105
- * The <code>q</code> query parameter can be used to get users that match the specified criteria <a href="https://auth0.com/docs/users/search/v3/query-syntax">using query string syntax.</a>
106
114
  *
107
- * <a href="https://auth0.com/docs/users/search/v3">Learn more about searching for users.</a>
108
115
  *
109
- * Read about <a href="https://auth0.com/docs/users/search/best-practices">best practices</a> when working with the API endpoints for retrieving users.
110
116
  *
111
- * Auth0 limits the number of users you can return. If you exceed this threshold, please redefine your search, use the <a href="https://auth0.com/docs/api/management/v2#!/Jobs/post_users_exports">export job</a>, or the <a href="https://auth0.com/docs/extensions/user-import-export">User Import / Export</a> extension.
117
+ * The `q` query parameter can be used to get users that match the specified criteria [using query string syntax.](https://auth0.com/docs/users/search/v3/query-syntax)
118
+ *
119
+ * [Learn more about searching for users.](https://auth0.com/docs/users/search/v3)
120
+ *
121
+ * Read about [best practices](https://auth0.com/docs/users/search/best-practices) when working with the API endpoints for retrieving users.
122
+ *
123
+ *
124
+ *
125
+ * Auth0 limits the number of users you can return. If you exceed this threshold, please redefine your search, use the [export job](https://auth0.com/docs/api/management/v2#!/Jobs/post_users_exports), or the [User Import / Export](https://auth0.com/docs/extensions/user-import-export) extension.
112
126
  *
113
127
  * @param {Management.ListUsersRequestParameters} request
114
128
  * @param {UsersClient.RequestOptions} requestOptions - Request-specific configuration.
@@ -210,9 +224,9 @@ export class UsersClient {
210
224
  });
211
225
  }
212
226
  /**
213
- * Create a new user for a given <a href="https://auth0.com/docs/connections/database">database</a> or <a href="https://auth0.com/docs/connections/passwordless">passwordless</a> connection.
227
+ * Create a new user for a given [database](https://auth0.com/docs/connections/database) or [passwordless](https://auth0.com/docs/connections/passwordless) connection.
214
228
  *
215
- * Note: <code>connection</code> is required but other parameters such as <code>email</code> and <code>password</code> are dependent upon the type of connection.
229
+ * Note: `connection` is required but other parameters such as `email` and `password` are dependent upon the type of connection.
216
230
  *
217
231
  * @param {Management.CreateUserRequestContent} request
218
232
  * @param {UsersClient.RequestOptions} requestOptions - Request-specific configuration.
@@ -352,7 +366,7 @@ export class UsersClient {
352
366
  });
353
367
  }
354
368
  /**
355
- * Retrieve user details. A list of fields to include or exclude may also be specified. For more information, see <a href="https://auth0.com/docs/manage-users/user-search/retrieve-users-with-get-users-endpoint">Retrieve Users with the Get Users Endpoint</a>.
369
+ * Retrieve user details. A list of fields to include or exclude may also be specified. For more information, see [Retrieve Users with the Get Users Endpoint](https://auth0.com/docs/manage-users/user-search/retrieve-users-with-get-users-endpoint).
356
370
  *
357
371
  * @param {string} id - ID of the user to retrieve.
358
372
  * @param {Management.GetUserRequestParameters} request
@@ -425,7 +439,7 @@ export class UsersClient {
425
439
  });
426
440
  }
427
441
  /**
428
- * Delete a user by user ID. This action cannot be undone. For Auth0 Dashboard instructions, see <a href="https://auth0.com/docs/manage-users/user-accounts/delete-users">Delete Users</a>.
442
+ * Delete a user by user ID. This action cannot be undone. For Auth0 Dashboard instructions, see [Delete Users](https://auth0.com/docs/manage-users/user-accounts/delete-users).
429
443
  *
430
444
  * @param {string} id - ID of the user to delete.
431
445
  * @param {UsersClient.RequestOptions} requestOptions - Request-specific configuration.
@@ -486,64 +500,84 @@ export class UsersClient {
486
500
  *
487
501
  * These are the attributes that can be updated at the root level:
488
502
  *
489
- * <ul>
490
- * <li>app_metadata</li>
491
- * <li>blocked</li>
492
- * <li>email</li>
493
- * <li>email_verified</li>
494
- * <li>family_name</li>
495
- * <li>given_name</li>
496
- * <li>name</li>
497
- * <li>nickname</li>
498
- * <li>password</li>
499
- * <li>phone_number</li>
500
- * <li>phone_verified</li>
501
- * <li>picture</li>
502
- * <li>username</li>
503
- * <li>user_metadata</li>
504
- * <li>verify_email</li>
505
- * </ul>
503
+ * - app_metadata
504
+ * - blocked
505
+ * - email
506
+ * - email_verified
507
+ * - family_name
508
+ * - given_name
509
+ * - name
510
+ * - nickname
511
+ * - password
512
+ * - phone_number
513
+ * - phone_verified
514
+ * - picture
515
+ * - username
516
+ * - user_metadata
517
+ * - verify_email
506
518
  *
507
519
  * Some considerations:
508
- * <ul>
509
- * <li>The properties of the new object will replace the old ones.</li>
510
- * <li>The metadata fields are an exception to this rule (<code>user_metadata</code> and <code>app_metadata</code>). These properties are merged instead of being replaced but be careful, the merge only occurs on the first level.</li>
511
- * <li>If you are updating <code>email</code>, <code>email_verified</code>, <code>phone_number</code>, <code>phone_verified</code>, <code>username</code> or <code>password</code> of a secondary identity, you need to specify the <code>connection</code> property too.</li>
512
- * <li>If you are updating <code>email</code> or <code>phone_number</code> you can specify, optionally, the <code>client_id</code> property.</li>
513
- * <li>Updating <code>email_verified</code> is not supported for enterprise and passwordless sms connections.</li>
514
- * <li>Updating the <code>blocked</code> to <code>false</code> does not affect the user's blocked state from an excessive amount of incorrectly provided credentials. Use the "Unblock a user" endpoint from the "User Blocks" API to change the user's state.</li>
515
- * <li>Supported attributes can be unset by supplying <code>null</code> as the value.</li>
516
- * </ul>
517
- *
518
- * <h5>Updating a field (non-metadata property)</h5>
520
+ *
521
+ * - The properties of the new object will replace the old ones.
522
+ * - The metadata fields are an exception to this rule (`user_metadata` and `app_metadata`). These properties are merged instead of being replaced but be careful, the merge only occurs on the first level.
523
+ * - If you are updating `email`, `email_verified`, `phone_number`, `phone_verified`, `username` or `password` of a secondary identity, you need to specify the `connection` property too.
524
+ * - If you are updating `email` or `phone_number` you can specify, optionally, the `client_id` property.
525
+ * - Updating `email_verified` is not supported for enterprise and passwordless sms connections.
526
+ * - Updating the `blocked` to `false` does not affect the user's blocked state from an excessive amount of incorrectly provided credentials. Use the "Unblock a user" endpoint from the "User Blocks" API to change the user's state.
527
+ * - Supported attributes can be unset by supplying `null` as the value.
528
+ *
529
+ * **Updating a field (non-metadata property)**
530
+ *
519
531
  * To mark the email address of a user as verified, the body to send should be:
520
- * <pre><code>{ "email_verified": true }</code></pre>
521
532
  *
522
- * <h5>Updating a user metadata root property</h5>Let's assume that our test user has the following <code>user_metadata</code>:
523
- * <pre><code>{ "user_metadata" : { "profileCode": 1479 } }</code></pre>
533
+ * ```json
534
+ * { "email_verified": true }
535
+ * ```
536
+ *
537
+ * **Updating a user metadata root property**
538
+ *
539
+ * Let's assume that our test user has the following `user_metadata`:
540
+ *
541
+ * ```json
542
+ * { "user_metadata" : { "profileCode": 1479 } }
543
+ * ```
524
544
  *
525
- * To add the field <code>addresses</code> the body to send should be:
526
- * <pre><code>{ "user_metadata" : { "addresses": {"work_address": "100 Industrial Way"} }}</code></pre>
545
+ * To add the field `addresses` the body to send should be:
527
546
  *
528
- * The modified object ends up with the following <code>user_metadata</code> property:<pre><code>{
547
+ * ```json
548
+ * { "user_metadata" : { "addresses": {"work_address": "100 Industrial Way"} }}
549
+ * ```
550
+ *
551
+ * The modified object ends up with the following `user_metadata` property:
552
+ *
553
+ * ```json
554
+ * {
529
555
  * "user_metadata": {
530
556
  * "profileCode": 1479,
531
557
  * "addresses": { "work_address": "100 Industrial Way" }
532
558
  * }
533
- * }</code></pre>
559
+ * }
560
+ * ```
561
+ *
562
+ * **Updating an inner user metadata property**
534
563
  *
535
- * <h5>Updating an inner user metadata property</h5>If there's existing user metadata to which we want to add <code>"home_address": "742 Evergreen Terrace"</code> (using the <code>addresses</code> property) we should send the whole <code>addresses</code> object. Since this is a first-level object, the object will be merged in, but its own properties will not be. The body to send should be:
536
- * <pre><code>{
564
+ * If there's existing user metadata to which we want to add `"home_address": "742 Evergreen Terrace"` (using the `addresses` property) we should send the whole `addresses` object. Since this is a first-level object, the object will be merged in, but its own properties will not be. The body to send should be:
565
+ *
566
+ * ```json
567
+ * {
537
568
  * "user_metadata": {
538
569
  * "addresses": {
539
570
  * "work_address": "100 Industrial Way",
540
571
  * "home_address": "742 Evergreen Terrace"
541
572
  * }
542
573
  * }
543
- * }</code></pre>
574
+ * }
575
+ * ```
576
+ *
577
+ * The modified object ends up with the following `user_metadata` property:
544
578
  *
545
- * The modified object ends up with the following <code>user_metadata</code> property:
546
- * <pre><code>{
579
+ * ```json
580
+ * {
547
581
  * "user_metadata": {
548
582
  * "profileCode": 1479,
549
583
  * "addresses": {
@@ -551,7 +585,8 @@ export class UsersClient {
551
585
  * "home_address": "742 Evergreen Terrace"
552
586
  * }
553
587
  * }
554
- * }</code></pre>
588
+ * }
589
+ * ```
555
590
  *
556
591
  * @param {string} id - ID of the user to update.
557
592
  * @param {Management.UpdateUserRequestContent} request
@@ -615,7 +650,7 @@ export class UsersClient {
615
650
  });
616
651
  }
617
652
  /**
618
- * Remove an existing multi-factor authentication (MFA) <a href="https://auth0.com/docs/secure/multi-factor-authentication/reset-user-mfa">recovery code</a> and generate a new one. If a user cannot access the original device or account used for MFA enrollment, they can use a recovery code to authenticate.
653
+ * Remove an existing multi-factor authentication (MFA) [recovery code](https://auth0.com/docs/secure/multi-factor-authentication/reset-user-mfa) and generate a new one. If a user cannot access the original device or account used for MFA enrollment, they can use a recovery code to authenticate.
619
654
  *
620
655
  * @param {string} id - ID of the user to regenerate a multi-factor authentication recovery code for.
621
656
  * @param {UsersClient.RequestOptions} requestOptions - Request-specific configuration.
@@ -10,7 +10,7 @@ export declare class AuthenticatorsClient {
10
10
  protected readonly _options: NormalizedClientOptionsWithAuth<AuthenticatorsClient.Options>;
11
11
  constructor(options: AuthenticatorsClient.Options);
12
12
  /**
13
- * Remove all authenticators registered to a given user ID, such as OTP, email, phone, and push-notification. This action cannot be undone. For more information, review <a href="https://auth0.com/docs/secure/multi-factor-authentication/manage-mfa-auth0-apis/manage-authentication-methods-with-management-api">Manage Authentication Methods with Management API</a>.
13
+ * Remove all authenticators registered to a given user ID, such as OTP, email, phone, and push-notification. This action cannot be undone. For more information, review [Manage Authentication Methods with Management API](https://auth0.com/docs/secure/multi-factor-authentication/manage-mfa-auth0-apis/manage-authentication-methods-with-management-api).
14
14
  *
15
15
  * @param {string} id - ID of the user to delete.
16
16
  * @param {AuthenticatorsClient.RequestOptions} requestOptions - Request-specific configuration.
@@ -20,7 +20,7 @@ export class AuthenticatorsClient {
20
20
  this._options = normalizeClientOptionsWithAuth(options);
21
21
  }
22
22
  /**
23
- * Remove all authenticators registered to a given user ID, such as OTP, email, phone, and push-notification. This action cannot be undone. For more information, review <a href="https://auth0.com/docs/secure/multi-factor-authentication/manage-mfa-auth0-apis/manage-authentication-methods-with-management-api">Manage Authentication Methods with Management API</a>.
23
+ * Remove all authenticators registered to a given user ID, such as OTP, email, phone, and push-notification. This action cannot be undone. For more information, review [Manage Authentication Methods with Management API](https://auth0.com/docs/secure/multi-factor-authentication/manage-mfa-auth0-apis/manage-authentication-methods-with-management-api).
24
24
  *
25
25
  * @param {string} id - ID of the user to delete.
26
26
  * @param {AuthenticatorsClient.RequestOptions} requestOptions - Request-specific configuration.
@@ -0,0 +1,37 @@
1
+ import type { BaseClientOptions, BaseRequestOptions } from "../../../../../../BaseClient.mjs";
2
+ import { type NormalizedClientOptionsWithAuth } from "../../../../../../BaseClient.mjs";
3
+ import * as core from "../../../../../../core/index.mjs";
4
+ import * as Management from "../../../../../index.mjs";
5
+ import { SourcesClient } from "../resources/sources/client/Client.mjs";
6
+ export declare namespace EffectivePermissionsClient {
7
+ type Options = BaseClientOptions;
8
+ interface RequestOptions extends BaseRequestOptions {
9
+ }
10
+ }
11
+ export declare class EffectivePermissionsClient {
12
+ protected readonly _options: NormalizedClientOptionsWithAuth<EffectivePermissionsClient.Options>;
13
+ protected _sources: SourcesClient | undefined;
14
+ constructor(options: EffectivePermissionsClient.Options);
15
+ get sources(): SourcesClient;
16
+ /**
17
+ * Returns the list of effective permissions for a user, taking into account permissions granted directly to the user, as well as those inherited through roles and group memberships.
18
+ *
19
+ * @param {string} id - ID of the user to retrieve the permissions for.
20
+ * @param {Management.ListUserEffectivePermissionsRequestParameters} request
21
+ * @param {EffectivePermissionsClient.RequestOptions} requestOptions - Request-specific configuration.
22
+ *
23
+ * @throws {@link Management.BadRequestError}
24
+ * @throws {@link Management.UnauthorizedError}
25
+ * @throws {@link Management.ForbiddenError}
26
+ * @throws {@link Management.NotFoundError}
27
+ * @throws {@link Management.TooManyRequestsError}
28
+ *
29
+ * @example
30
+ * await client.users.effectivePermissions.list("id", {
31
+ * from: "from",
32
+ * take: 1,
33
+ * resource_server_identifier: "resource_server_identifier"
34
+ * })
35
+ */
36
+ list(id: string, request: Management.ListUserEffectivePermissionsRequestParameters, requestOptions?: EffectivePermissionsClient.RequestOptions): Promise<core.Page<Management.UserEffectivePermissionResponseContent, Management.ListUserEffectivePermissionsResponseContent>>;
37
+ }
@@ -0,0 +1,114 @@
1
+ // This file was auto-generated by Fern from our API Definition.
2
+ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
3
+ function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
4
+ return new (P || (P = Promise))(function (resolve, reject) {
5
+ function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
6
+ function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
7
+ function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
8
+ step((generator = generator.apply(thisArg, _arguments || [])).next());
9
+ });
10
+ };
11
+ import { normalizeClientOptionsWithAuth } from "../../../../../../BaseClient.mjs";
12
+ import * as core from "../../../../../../core/index.mjs";
13
+ import { mergeHeaders } from "../../../../../../core/headers.mjs";
14
+ import * as environments from "../../../../../../environments.mjs";
15
+ import { handleNonStatusCodeError } from "../../../../../../errors/handleNonStatusCodeError.mjs";
16
+ import * as errors from "../../../../../../errors/index.mjs";
17
+ import * as Management from "../../../../../index.mjs";
18
+ import { SourcesClient } from "../resources/sources/client/Client.mjs";
19
+ export class EffectivePermissionsClient {
20
+ constructor(options) {
21
+ this._options = normalizeClientOptionsWithAuth(options);
22
+ }
23
+ get sources() {
24
+ var _a;
25
+ return ((_a = this._sources) !== null && _a !== void 0 ? _a : (this._sources = new SourcesClient(this._options)));
26
+ }
27
+ /**
28
+ * Returns the list of effective permissions for a user, taking into account permissions granted directly to the user, as well as those inherited through roles and group memberships.
29
+ *
30
+ * @param {string} id - ID of the user to retrieve the permissions for.
31
+ * @param {Management.ListUserEffectivePermissionsRequestParameters} request
32
+ * @param {EffectivePermissionsClient.RequestOptions} requestOptions - Request-specific configuration.
33
+ *
34
+ * @throws {@link Management.BadRequestError}
35
+ * @throws {@link Management.UnauthorizedError}
36
+ * @throws {@link Management.ForbiddenError}
37
+ * @throws {@link Management.NotFoundError}
38
+ * @throws {@link Management.TooManyRequestsError}
39
+ *
40
+ * @example
41
+ * await client.users.effectivePermissions.list("id", {
42
+ * from: "from",
43
+ * take: 1,
44
+ * resource_server_identifier: "resource_server_identifier"
45
+ * })
46
+ */
47
+ list(id, request, requestOptions) {
48
+ return __awaiter(this, void 0, void 0, function* () {
49
+ const list = core.HttpResponsePromise.interceptFunction((request) => __awaiter(this, void 0, void 0, function* () {
50
+ var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
51
+ const { from: from_, take = 50, resource_server_identifier: resourceServerIdentifier } = request;
52
+ const _queryParams = {
53
+ from: from_,
54
+ take,
55
+ resource_server_identifier: resourceServerIdentifier,
56
+ };
57
+ const _authRequest = yield this._options.authProvider.getAuthRequest();
58
+ let _headers = mergeHeaders(_authRequest.headers, (_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
59
+ const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
60
+ url: core.url.join((_d = (_c = (yield core.Supplier.get(this._options.baseUrl))) !== null && _c !== void 0 ? _c : (yield core.Supplier.get(this._options.environment))) !== null && _d !== void 0 ? _d : environments.ManagementEnvironment.Default, `users/${core.url.encodePathParam(id)}/effective-permissions`),
61
+ method: "GET",
62
+ headers: _headers,
63
+ queryString: core.url
64
+ .queryBuilder()
65
+ .addMany(_queryParams)
66
+ .mergeAdditional(requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams)
67
+ .build(),
68
+ timeoutMs: ((_g = (_e = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _e !== void 0 ? _e : (_f = this._options) === null || _f === void 0 ? void 0 : _f.timeoutInSeconds) !== null && _g !== void 0 ? _g : 60) * 1000,
69
+ maxRetries: (_h = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _h !== void 0 ? _h : (_j = this._options) === null || _j === void 0 ? void 0 : _j.maxRetries,
70
+ abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
71
+ fetchFn: (_k = this._options) === null || _k === void 0 ? void 0 : _k.fetch,
72
+ logging: this._options.logging,
73
+ });
74
+ if (_response.ok) {
75
+ return {
76
+ data: _response.body,
77
+ rawResponse: _response.rawResponse,
78
+ };
79
+ }
80
+ if (_response.error.reason === "status-code") {
81
+ switch (_response.error.statusCode) {
82
+ case 400:
83
+ throw new Management.BadRequestError(_response.error.body, _response.rawResponse);
84
+ case 401:
85
+ throw new Management.UnauthorizedError(_response.error.body, _response.rawResponse);
86
+ case 403:
87
+ throw new Management.ForbiddenError(_response.error.body, _response.rawResponse);
88
+ case 404:
89
+ throw new Management.NotFoundError(_response.error.body, _response.rawResponse);
90
+ case 429:
91
+ throw new Management.TooManyRequestsError(_response.error.body, _response.rawResponse);
92
+ default:
93
+ throw new errors.ManagementError({
94
+ statusCode: _response.error.statusCode,
95
+ body: _response.error.body,
96
+ rawResponse: _response.rawResponse,
97
+ });
98
+ }
99
+ }
100
+ return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/users/{id}/effective-permissions");
101
+ }));
102
+ const dataWithRawResponse = yield list(request).withRawResponse();
103
+ return new core.Page({
104
+ response: dataWithRawResponse.data,
105
+ rawResponse: dataWithRawResponse.rawResponse,
106
+ hasNextPage: (response) => (response === null || response === void 0 ? void 0 : response.next) != null && !(typeof (response === null || response === void 0 ? void 0 : response.next) === "string" && (response === null || response === void 0 ? void 0 : response.next) === ""),
107
+ getItems: (response) => { var _a; return (_a = response === null || response === void 0 ? void 0 : response.permissions) !== null && _a !== void 0 ? _a : []; },
108
+ loadPage: (response) => {
109
+ return list(core.setObjectProperty(request, "from", response === null || response === void 0 ? void 0 : response.next));
110
+ },
111
+ });
112
+ });
113
+ }
114
+ }