From 7b6f69dd7b28d6127b3e4e7ae48c2d89f233b80d Mon Sep 17 00:00:00 2001 From: speakeasybot Date: Mon, 21 Sep 2026 00:18:17 +0000 Subject: [PATCH] ## Java SDK Changes: * `clerk.sessions.getReverification()`: **Added** * `clerk.phoneNumbers.attemptVerification()`: `error` **Changed** * `clerk.users.list()`: `response.[]` **Changed** * `clerk.users.create()`: `response` **Changed** * `clerk.users.get()`: `response` **Changed** * `clerk.users.update()`: `response` **Changed** * `clerk.users.ban()`: `response` **Changed** * `clerk.users.unban()`: `response` **Changed** * `clerk.users.bulkBan()`: `response.[]` **Changed** * `clerk.users.bulkUnban()`: `response.[]` **Changed** * `clerk.users.lock()`: `response` **Changed** * `clerk.users.unlock()`: `response` **Changed** * `clerk.users.setProfileImage()`: `response` **Changed** * `clerk.users.deleteProfileImage()`: `response` **Changed** * `clerk.users.updateMetadata()`: `response` **Changed** * `clerk.users.replaceMetadata()`: `response` **Changed** * `clerk.users.removePassword()`: `response` **Changed** * `clerk.users.setPasswordCompromised()`: `response` **Changed** * `clerk.users.unsetPasswordCompromised()`: `response` **Changed** * `clerk.domains.add()`: * `request.isSatellite` **Changed** * `clerk.oauthAccessTokens.verify()`: `response.union(1).aud` **Added** --- .speakeasy/gen.lock | 241 ++++++--- .speakeasy/gen.yaml | 2 +- .speakeasy/workflow.lock | 12 +- README.md | 77 +-- RELEASES.md | 12 +- docs/models/components/BillingStatement.md | 2 +- .../components/BillingStatementGroups.md | 12 + docs/models/components/Groups.md | 11 +- docs/models/components/Level.md | 20 + docs/models/components/Reverification.md | 20 + .../models/components/ReverificationObject.md | 19 + .../models/components/ReverificationStatus.md | 18 + docs/models/components/SCIMUserMetadata.md | 18 + docs/models/components/Scim.md | 20 +- docs/models/components/User.md | 4 +- docs/models/components/UserDirectory.md | 19 + docs/models/components/UserGroups.md | 9 + docs/models/components/UserScimGroups.md | 9 + .../models/operations/AddDomainRequestBody.md | 10 +- .../CreateOAuthApplicationRequestBody.md | 20 +- docs/models/operations/DeleteDomainRequest.md | 6 +- .../operations/GetReverificationRequest.md | 9 + .../operations/GetReverificationResponse.md | 11 + docs/models/operations/ResponseBody1.md | 1 + .../UpdateOAuthApplicationRequestBody.md | 2 +- docs/sdks/domains/README.md | 17 +- docs/sdks/phonenumbers/README.md | 20 +- docs/sdks/sessions/README.md | 55 ++ docs/sdks/users/README.md | 2 +- gradle.properties | 2 +- .../java/com/clerk/backend_api/Domains.java | 43 +- .../com/clerk/backend_api/PhoneNumbers.java | 30 +- .../clerk/backend_api/SDKConfiguration.java | 4 +- .../java/com/clerk/backend_api/Sessions.java | 63 +++ .../java/com/clerk/backend_api/Users.java | 9 +- .../models/components/BillingStatement.java | 12 +- .../components/BillingStatementGroups.java | 187 +++++++ .../backend_api/models/components/Groups.java | 144 ++---- .../backend_api/models/components/Level.java | 41 ++ .../models/components/Reverification.java | 487 ++++++++++++++++++ .../components/ReverificationObject.java | 39 ++ .../components/ReverificationStatus.java | 36 ++ .../models/components/SCIMUserMetadata.java | 430 ++++++++++++++++ .../backend_api/models/components/Scim.java | 264 ++++++++-- .../backend_api/models/components/User.java | 189 ++++++- .../models/components/UserDirectory.java | 432 ++++++++++++++++ .../models/components/UserGroups.java | 119 +++++ .../models/components/UserScimGroups.java | 119 +++++ .../operations/AddDomainRequestBody.java | 48 +- .../CreateOAuthApplicationRequestBody.java | 24 +- .../operations/DeleteDomainRequest.java | 8 +- .../operations/GetReverificationRequest.java | 141 +++++ .../GetReverificationRequestBuilder.java | 73 +++ .../operations/GetReverificationResponse.java | 253 +++++++++ .../models/operations/ResponseBody1.java | 80 ++- .../UpdateOAuthApplicationRequestBody.java | 30 +- .../AttemptPhoneNumberVerification.java | 2 +- .../operations/GetReverification.java | 213 ++++++++ 58 files changed, 3805 insertions(+), 395 deletions(-) create mode 100644 docs/models/components/BillingStatementGroups.md create mode 100644 docs/models/components/Level.md create mode 100644 docs/models/components/Reverification.md create mode 100644 docs/models/components/ReverificationObject.md create mode 100644 docs/models/components/ReverificationStatus.md create mode 100644 docs/models/components/SCIMUserMetadata.md create mode 100644 docs/models/components/UserDirectory.md create mode 100644 docs/models/components/UserGroups.md create mode 100644 docs/models/components/UserScimGroups.md create mode 100644 docs/models/operations/GetReverificationRequest.md create mode 100644 docs/models/operations/GetReverificationResponse.md create mode 100644 src/main/java/com/clerk/backend_api/models/components/BillingStatementGroups.java create mode 100644 src/main/java/com/clerk/backend_api/models/components/Level.java create mode 100644 src/main/java/com/clerk/backend_api/models/components/Reverification.java create mode 100644 src/main/java/com/clerk/backend_api/models/components/ReverificationObject.java create mode 100644 src/main/java/com/clerk/backend_api/models/components/ReverificationStatus.java create mode 100644 src/main/java/com/clerk/backend_api/models/components/SCIMUserMetadata.java create mode 100644 src/main/java/com/clerk/backend_api/models/components/UserDirectory.java create mode 100644 src/main/java/com/clerk/backend_api/models/components/UserGroups.java create mode 100644 src/main/java/com/clerk/backend_api/models/components/UserScimGroups.java create mode 100644 src/main/java/com/clerk/backend_api/models/operations/GetReverificationRequest.java create mode 100644 src/main/java/com/clerk/backend_api/models/operations/GetReverificationRequestBuilder.java create mode 100644 src/main/java/com/clerk/backend_api/models/operations/GetReverificationResponse.java create mode 100644 src/main/java/com/clerk/backend_api/operations/GetReverification.java diff --git a/.speakeasy/gen.lock b/.speakeasy/gen.lock index 5e32cfe0..d09cabae 100755 --- a/.speakeasy/gen.lock +++ b/.speakeasy/gen.lock @@ -1,19 +1,19 @@ lockVersion: 2.0.0 id: 1d22a5a4-8bac-42e3-b164-121fcacf66c9 management: - docChecksum: a50b5e4da9b53aa838201bcc1a2cba0a + docChecksum: b03e3390aaa6e645468a26976949a077 docVersion: "2026-05-12" - speakeasyVersion: 1.797.0 - generationVersion: 2.937.18 - releaseVersion: 6.1.0 - configChecksum: c8793a5edefe2fcbc56dbadb8c92cc83 + speakeasyVersion: 1.798.0 + generationVersion: 2.938.0 + releaseVersion: 6.1.1 + configChecksum: c7d1c4ee49ae00447c631688672a8629 repoURL: https://github.com/clerk/clerk-sdk-java.git installationURL: https://github.com/clerk/clerk-sdk-java published: true persistentEdits: - generation_id: 4948a2ca-940d-45e5-93ba-ad334702d62d - pristine_commit_hash: 7c39e62a50989cf6baef384258a8801cbe4166df - pristine_tree_hash: cad4f8ca1b2efb289ee9dea45df56627b0a9f297 + generation_id: 036d4ae9-92f2-461d-a37d-4951b44eb8fc + pristine_commit_hash: 1bd384cd7d2ecd64f2bfc53c62d022579e4f1ff7 + pristine_tree_hash: 7035df3c103600142a602bec5bc3cfcdd636beaa features: java: additionalDependencies: 0.1.0 @@ -186,8 +186,12 @@ trackedFiles: pristine_git_object: 1db90fdb5bc98e05e2cae4074982ff629f21f902 docs/models/components/BillingStatement.md: id: 08ee6837c35e - last_write_checksum: sha1:c4e180b7049b52ef7866d49bf3765e208062a14b - pristine_git_object: 0de53e97a287293cdc05dcbb91c1556c9019e9ad + last_write_checksum: sha1:d14188aa60fda7688f7b52424f9b91321b1d25c1 + pristine_git_object: dfec04a2e769d0d5425f3864ab728c96d70ad9db + docs/models/components/BillingStatementGroups.md: + id: a3034b6b7e6c + last_write_checksum: sha1:06736290079b37fe463475843841f4f04e57ea21 + pristine_git_object: 7afa3509285c311c197bcb97391072569e14ba19 docs/models/components/BillingStatementGroupsObject.md: id: 1694a317c302 last_write_checksum: sha1:e2b344f1944dd8fe004e30cfc3eed4dad852c562 @@ -858,8 +862,8 @@ trackedFiles: pristine_git_object: e6ec885fa971b30889934fbd0a809d605b53e1ac docs/models/components/Groups.md: id: 24a77eec8bca - last_write_checksum: sha1:d703b6adc997d10e2f7268af45f1281460a43a0b - pristine_git_object: 9621d07cfefac3bb172854cea0b927961902f40b + last_write_checksum: sha1:2fcda54ea3efec96669e4d7ad66e481935e7b621 + pristine_git_object: 10202ee6f59a9d7cfe3e2536c027bab5d4950e93 docs/models/components/IdentificationLink.md: id: 06cbf49a828c last_write_checksum: sha1:8a85b1c88b24c43760c00f75b89567ad19951fba @@ -952,6 +956,10 @@ trackedFiles: id: d3ad1d049a49 last_write_checksum: sha1:e72dea77b6b0db9415cfa43afcfffe0a075159cc pristine_git_object: 0b3bf6b3b965f7a16d4614359cec95d5868d49b8 + docs/models/components/Level.md: + id: f7059b7ba5c8 + last_write_checksum: sha1:1b60ff63f60cd53ec1132d6d3be43faf09b6d935 + pristine_git_object: d03e8d2e78a9a976d40c74ff795b80747c2317d5 docs/models/components/LifetimePaid.md: id: d9512dfe3805 last_write_checksum: sha1:f5cd8f8400d64825c0cec4a64cd69c3a347615e8 @@ -1336,6 +1344,18 @@ trackedFiles: id: 6e264e934cc8 last_write_checksum: sha1:fd6b2e59069adcb89a8aff5e40965bb14ee4186c pristine_git_object: bc4b7e1ea0c167769b57367c79207afbd967c0f2 + docs/models/components/Reverification.md: + id: 99bf1d6e69d6 + last_write_checksum: sha1:32a665175539cad4073b77dfcdf45d3df1689930 + pristine_git_object: 27bd08fe426c3b13718ad171e3bb0d3e4712a28f + docs/models/components/ReverificationObject.md: + id: 8785cc7bd317 + last_write_checksum: sha1:2825eea33297bf91c7f9262a64656a6e4a6111f9 + pristine_git_object: cf6b1afb54e10d3eaf5632d959aba968dd935b23 + docs/models/components/ReverificationStatus.md: + id: efda409d6c71 + last_write_checksum: sha1:26beeadadffb04c2405ac93e5025d05548eac21d + pristine_git_object: f58b0c1241f9f5ebcdb25a2a78eccb5832135e49 docs/models/components/Role.md: id: c89eff3746a7 last_write_checksum: sha1:eb82b7fbfd06c498ebe6a9b1840d1ecf538dafb3 @@ -1472,14 +1492,18 @@ trackedFiles: id: 6a7ed336a29c last_write_checksum: sha1:e073911c8cdde2e62338b497ed10e23fd815968c pristine_git_object: 273a13e594743d7238cc0965024ef368842a59b1 + docs/models/components/SCIMUserMetadata.md: + id: 1cad9df62b95 + last_write_checksum: sha1:8c7364277e3c2a8d32554a559c2454bbce61067c + pristine_git_object: e210e061d9d81428110ed7bc0694c8516f675a50 docs/models/components/Saml.md: id: b76d2a069b63 last_write_checksum: sha1:7967b6bd931507e9b4e8d5052013e28deee80252 pristine_git_object: 0b1a091b76d4e18dec28d4f419998aa74d896d28 docs/models/components/Scim.md: id: 15d999cacc52 - last_write_checksum: sha1:a56d68b29e0463f9f29135c71fd3d892fd4c6b9d - pristine_git_object: f23887a977e8de4f0bf5f9f065c5d70325ccbaf9 + last_write_checksum: sha1:8d49e7050d12e84b8af5702cfbb3057e12072be8 + pristine_git_object: 133bb38b25fd7505ec6abae24b991eb60dc601eb docs/models/components/Seats.md: id: ca6ade4bd7ea last_write_checksum: sha1:e168a6abad2bf8167b74160443da1d98b43cacd5 @@ -1634,12 +1658,24 @@ trackedFiles: pristine_git_object: 5005e4a5864ce390660dd60e17fbc12f456e9f4b docs/models/components/User.md: id: 8f2722ab45f3 - last_write_checksum: sha1:6ad697f7d9ac306bc6f57619b42cc63d5ec47256 - pristine_git_object: 132abd4f1171bea720d4be3d9559d7ffeafc7403 + last_write_checksum: sha1:268650cd2069c0513b49d52cf99edda55df949ab + pristine_git_object: d026486368ac0f74c304486172cbca02eb835c8b + docs/models/components/UserDirectory.md: + id: 1a3dcc023644 + last_write_checksum: sha1:ec11b91c102fc9e01e8407aa6ff036ee0e8d0665 + pristine_git_object: 00380151f8ce0ca079ea3b6d575d228f345670f6 + docs/models/components/UserGroups.md: + id: 42c0cc7576e8 + last_write_checksum: sha1:ce148e9f366fd89d7a3e9f436a0f3cc7d1e76a86 + pristine_git_object: c27b02da19a6da6e0dfa1489d69f76dd588923be docs/models/components/UserObject.md: id: 9d7bc67de5a8 last_write_checksum: sha1:93d67bda70a564f58c319ddbc99a5443182d2207 pristine_git_object: 6777bf5dd0cc712427c841cfc1ad7ded4c726bed + docs/models/components/UserScimGroups.md: + id: 63969bd295af + last_write_checksum: sha1:8bfc3d2b6827461dc4c807ee6fe67ad1cf39ab84 + pristine_git_object: 781c9e9438672120094246a6ea33cc06ddf0c4cf docs/models/components/Verification.md: id: b218a37e4a83 last_write_checksum: sha1:17be7334e58ebe2fd47ca47a010d7e60a053a4bf @@ -2290,8 +2326,8 @@ trackedFiles: pristine_git_object: 55c4494e9dfce40b5005f08c6bb9a8bad14f3210 docs/models/operations/AddDomainRequestBody.md: id: 88405b0482f2 - last_write_checksum: sha1:41e91508a8680bf81c72d6c3de542ed9fe13b983 - pristine_git_object: 0f688f57908ef5472cc4d0552a8847a68fbd1a6e + last_write_checksum: sha1:2a069ebcac28d314ec2b71376db084eb95daf245 + pristine_git_object: c6a3fc0d0b5891ac03792883139c0e0758bc5603 docs/models/operations/AddDomainResponse.md: id: 01b8b6acd4d2 last_write_checksum: sha1:bcfcabe17a751388f40f491c6976f199e14cc584 @@ -2606,8 +2642,8 @@ trackedFiles: pristine_git_object: d960998eb10011182fabfff588aca5fa13a0dd75 docs/models/operations/CreateOAuthApplicationRequestBody.md: id: 241e1a47481d - last_write_checksum: sha1:5d37dba32a2bffc502002eb65885fb25698e9100 - pristine_git_object: b432dd40f219dae9e59f2988021345784e8d468c + last_write_checksum: sha1:690a99c9cb2ed03553a6925e0ca416f0186f8871 + pristine_git_object: 25c7f8a5f57302a7ff2bd135541fb6526f0d7c8d docs/models/operations/CreateOAuthApplicationResponse.md: id: f6287cc00011 last_write_checksum: sha1:87a024be3c3ac450af30dd8cf2bde7c92585513c @@ -2898,8 +2934,8 @@ trackedFiles: pristine_git_object: 9b5858a81966dafac122f714045c48bc0ef7aa38 docs/models/operations/DeleteDomainRequest.md: id: d5fe9ce68eab - last_write_checksum: sha1:5bfe1951a4b08ab143f9489309b24c8a1c661a4f - pristine_git_object: 3214099eab55c52a8f84796381d6fe69c3096e8b + last_write_checksum: sha1:62da895104bdc7c6eba07a5ed632aaf851ad6377 + pristine_git_object: a7d4e1bdc7b55680782862e0c7d6a0a7a302adf0 docs/models/operations/DeleteDomainResponse.md: id: 8e7843d6dbf1 last_write_checksum: sha1:a7ecce65b979d009ad81fcbb28b901c1e7cda5dd @@ -3416,6 +3452,14 @@ trackedFiles: id: b6bfcd2b8a42 last_write_checksum: sha1:c6745de6cd7babc006e93b1f4660862846c49033 pristine_git_object: 325bcdbdf6486dd89fa75eccc5fc27a445820bd8 + docs/models/operations/GetReverificationRequest.md: + id: 188daaaaa0e3 + last_write_checksum: sha1:ca8b742985a8a3d29e17aedb8ab912a1deb9d644 + pristine_git_object: acb8874fa5fbdc11829c9c18da8cf92883e12d16 + docs/models/operations/GetReverificationResponse.md: + id: efe4a6e741a5 + last_write_checksum: sha1:9d5f5cc73fa3f648bd08ea16234864702dc0b042 + pristine_git_object: 6400f720ae78d8255bc621942fc528c31593aead docs/models/operations/GetRoleSetRequest.md: id: e43866d4ee09 last_write_checksum: sha1:384f856ef34b8afbf1be41d52678cb3d09e9c93f @@ -4078,8 +4122,8 @@ trackedFiles: pristine_git_object: f796775dee5ee1206c6e098f533dafa637f6dde3 docs/models/operations/ResponseBody1.md: id: d00fdbdc8123 - last_write_checksum: sha1:eb101af0aa62ad9d1950032bff611f4a1a972aee - pristine_git_object: 476bc0f1de857804edf580a3da01323921584a15 + last_write_checksum: sha1:0980fb726baec2c232b68ae76102014eaea9af4f + pristine_git_object: 06ab4d2aa4516f56d08452508587e7330346fa76 docs/models/operations/ResponseBody2.md: id: ba973d70500b last_write_checksum: sha1:147ba4db77854ffbbda7d2019c561ba85b269743 @@ -4550,8 +4594,8 @@ trackedFiles: pristine_git_object: 26cb68380b5cdc431aebeca557f79f458dc52c48 docs/models/operations/UpdateOAuthApplicationRequestBody.md: id: 519af88526ab - last_write_checksum: sha1:a8d0b81b2ba7ebd143e8c4fcad2536fb36a2e037 - pristine_git_object: 5a63e9fc6424b50da051b64fcb7e46edd6c1ea4d + last_write_checksum: sha1:0b2d95d3f16d5213b0a2941a1ef160a492d197ed + pristine_git_object: 209972f9c7c4f764a5817df6d1253292bd4f75cd docs/models/operations/UpdateOAuthApplicationResponse.md: id: e644cc15d391 last_write_checksum: sha1:e437460e5c8d6bc67a917de11ec722c526cd7d9a @@ -4966,8 +5010,8 @@ trackedFiles: pristine_git_object: d804522632d5cbcc9f8ebab2b47a050f7897a56b docs/sdks/domains/README.md: id: 06e9beb4063b - last_write_checksum: sha1:6b79511f264ab3e82e4cec02d78b1c825989ea1e - pristine_git_object: afae3fa37ede54db928cebc6365e9f24615a3f82 + last_write_checksum: sha1:d500137ad621d557fcd0b90b564f689e9b77d43c + pristine_git_object: 46a29053cd36fd55b44a4a09bddd2d7caf5bd112 docs/sdks/emailaddresses/README.md: id: f5fd208070d3 last_write_checksum: sha1:1441f68bd79e238ae5e0296cdd90bc9ca74c4998 @@ -5046,8 +5090,8 @@ trackedFiles: pristine_git_object: e5014e78c10919fdc85b4873a2c12029896d018c docs/sdks/phonenumbers/README.md: id: bfed92f30c8c - last_write_checksum: sha1:30ec3517da1c7e4a25cf1cdff33215221d20f9ad - pristine_git_object: 69e0254fae57eb110358010b7e620ab04320cd4e + last_write_checksum: sha1:311fd07799fdf1875e53032922a3fb6257a22043 + pristine_git_object: 2672a283d51a0aec51e698841260c9a9bb590851 docs/sdks/proxychecks/README.md: id: b7b7c7dd6d7b last_write_checksum: sha1:2d9dc8f9cbfa45249fc7cbd0fa729a6520eb4e29 @@ -5070,8 +5114,8 @@ trackedFiles: pristine_git_object: d1501247b868426fdc7bed0cab2b98864097a029 docs/sdks/sessions/README.md: id: 57ad62844f79 - last_write_checksum: sha1:2f49edccab12e69d351ada28016c854c007cdb2e - pristine_git_object: 5af8f59f349e0893bb6fccd293ecdf894fff96d4 + last_write_checksum: sha1:c2459eeeef6b3c8b20f64dfb8c4bafd9ded20366 + pristine_git_object: 3e15dff6108e8ef9f9f93cd6b154391404590df4 docs/sdks/signintokens/README.md: id: 1fc872e39b51 last_write_checksum: sha1:3601da5bce43f76ce929b365c478deff40f12532 @@ -5090,8 +5134,8 @@ trackedFiles: pristine_git_object: 9ee3bca6022fca25977862c6abda580f3def47c1 docs/sdks/users/README.md: id: 5d80027045fe - last_write_checksum: sha1:bd4123134b3a7388f727ef84ecd60022985af5e7 - pristine_git_object: 1f4b7d79b22ac8b79989272fb827ece71a42262a + last_write_checksum: sha1:b96affbdcfca900bd0c9e5a2c1d3d3c43577e799 + pristine_git_object: 1898d70a97ac7d87d3f9b4983b9ae43ef588827d docs/sdks/waitlistentries/README.md: id: a4b511c18a9a last_write_checksum: sha1:eeef8b5b3c90024d3d0b5df790786dac86e9988c @@ -5102,8 +5146,8 @@ trackedFiles: pristine_git_object: 45f47ee13644598aaf91efff776b5e331d062373 gradle.properties: id: 2afbb999f001 - last_write_checksum: sha1:bca27b3743c8ef87b5143c7102948f4e7cb9e3e4 - pristine_git_object: 6bc1b685b48352d07c3e99711a613902bf7a07d0 + last_write_checksum: sha1:ac14f99ab7e017c1a71da9e9ada110e9b483975e + pristine_git_object: 905a0fff6580a90b93240562bf10a2deeec792a0 gradle/wrapper/gradle-wrapper.jar: id: ec27dae6e852 last_write_checksum: sha1:f725fb1467084142d74fd7cd8eab691ab3442611 @@ -5174,8 +5218,8 @@ trackedFiles: pristine_git_object: 50dd3cc87228a943011a5594d4553ff16f881dcd src/main/java/com/clerk/backend_api/Domains.java: id: b3c36a038460 - last_write_checksum: sha1:12cc9d89e3ee46356dcec088952a612db7a91968 - pristine_git_object: 88147167b275430ad91039cf855a088f6c290f34 + last_write_checksum: sha1:72bd2413fceb6fd0810d50dff8abc373ae1849ca + pristine_git_object: 7c67bb16d40cf66c9edb2e5d68f0543097ebfc82 src/main/java/com/clerk/backend_api/EmailAddresses.java: id: bfe4e0517e19 last_write_checksum: sha1:9ed051f6e3bc31b91977ffc1c63e38cdbda44724 @@ -5254,8 +5298,8 @@ trackedFiles: pristine_git_object: ac5f251a98304ff8ae6502f9bbda4a7591f45d8b src/main/java/com/clerk/backend_api/PhoneNumbers.java: id: a9bababa47f8 - last_write_checksum: sha1:126d2fbad0709daaf645876d13149c4d2fb2f730 - pristine_git_object: 3af70936fb9cc8e38b2cd5dfdeda9f3cfcb0ae80 + last_write_checksum: sha1:0f1536a0c307ed710b8fceba6301d8b23e0fcaf9 + pristine_git_object: 8aac9dd4f8f689a12c660fed55c3fb92be4ed4c7 src/main/java/com/clerk/backend_api/ProxyChecks.java: id: b3073c31ab8f last_write_checksum: sha1:1ae509f5cc48dbc3cda44f92f28b250688691c1e @@ -5270,8 +5314,8 @@ trackedFiles: pristine_git_object: 40597c8205e6e12003fcdad6e1d4f084c674effd src/main/java/com/clerk/backend_api/SDKConfiguration.java: id: 02084533ec5b - last_write_checksum: sha1:425dd6324aa9415f06db3781719ad6b2fa503458 - pristine_git_object: 963220becd4c16eafab7627be33695991cf0db5d + last_write_checksum: sha1:9f0bce0dc17eaa56840a74b26f3e7841c32d512d + pristine_git_object: ddcdbb460817ac1a0ad67d6f7718aa4cb0173eee src/main/java/com/clerk/backend_api/SamlConnections.java: id: 4bbf4e5d0a3c last_write_checksum: sha1:2e48c2a616261bcc34ae98b7f96b9eacfa8cdee6 @@ -5286,8 +5330,8 @@ trackedFiles: pristine_git_object: 96a4cac6409a1619225031b073aaa1b597d9db72 src/main/java/com/clerk/backend_api/Sessions.java: id: 7216918045dd - last_write_checksum: sha1:9bb61b0b1f0d51c52531f94ffdb0d991a82851ea - pristine_git_object: 3dae2e4fee56ac9df4719a2e0c4000aabd99e779 + last_write_checksum: sha1:db8c930b5ca3d21eb21ba0ea2bc17c975a46aea7 + pristine_git_object: 17a4cce6c4d3093675ac3c489fda442332ccb998 src/main/java/com/clerk/backend_api/SignInTokens.java: id: b35294056da4 last_write_checksum: sha1:45667f01b8bea06d2697cf3df387ef0fc8aab37e @@ -5306,8 +5350,8 @@ trackedFiles: pristine_git_object: 2d6d35e80ad878256a7a1a71c241668889c0e0e6 src/main/java/com/clerk/backend_api/Users.java: id: 25ce71c73baa - last_write_checksum: sha1:8e30aed578c561d6e4ca1ac96af9dac670b59a53 - pristine_git_object: c0fe9642e230044a41e21cdad9d983899bb4b84b + last_write_checksum: sha1:7ff16eefde19dcef316bb3c4a770669e0b639318 + pristine_git_object: 3784fe5eff7e75394ee84b7987e1f0900f0ff813 src/main/java/com/clerk/backend_api/WaitlistEntries.java: id: 5008ff59b95b last_write_checksum: sha1:47fa5ea495bc9740ea46051ec71a584b5c6a64fe @@ -5454,8 +5498,12 @@ trackedFiles: pristine_git_object: 25dea86e71a1110770edff8b1066e87e7a091c14 src/main/java/com/clerk/backend_api/models/components/BillingStatement.java: id: a0a4157e3362 - last_write_checksum: sha1:174008a84a6690908aa1f0fb25aaef4dd6ebe677 - pristine_git_object: 68fe8ec3b480832f548a15551b7109214996ac73 + last_write_checksum: sha1:53cab922db074145e50340505b97f989e34ad7d2 + pristine_git_object: 3ab1a618427c1d03521bbe4035db3ce6d2684a97 + src/main/java/com/clerk/backend_api/models/components/BillingStatementGroups.java: + id: da69f90def69 + last_write_checksum: sha1:aada017893aa8a1db29463b93aa2367c63de5f49 + pristine_git_object: e90b4d5083c54dd04dc88b0ab7ae4b7a46911f1d src/main/java/com/clerk/backend_api/models/components/BillingStatementGroupsObject.java: id: 888d6b0f1e78 last_write_checksum: sha1:7467039f8b52a7174582313aa18d7b3ea1567d68 @@ -6134,8 +6182,8 @@ trackedFiles: pristine_git_object: a05fd8eb1e97e2b870e7dcbd40d84cf0e2ebd99a src/main/java/com/clerk/backend_api/models/components/Groups.java: id: dde6358a24fa - last_write_checksum: sha1:bc1127a1e4be380ed9b004a77de94dc960a3515b - pristine_git_object: 34afa3629944ccdd6cfeb7c24330c85dcdb87520 + last_write_checksum: sha1:db09f44962ce80d7107a35bd17c543d1ae3f0e7f + pristine_git_object: 325aa437f37d8fa424aa91fff0df483e8b427f4c src/main/java/com/clerk/backend_api/models/components/IdentificationLink.java: id: c4d768ae3ffd last_write_checksum: sha1:2f60ec9dd9791b65298d6a4f3c6c44854a3bf1c5 @@ -6228,6 +6276,10 @@ trackedFiles: id: 6e360f2d0afd last_write_checksum: sha1:66477ea9f2064c23b788f9317ceeed99e8c09568 pristine_git_object: 6cb4e1e5b03cbdf384b4955cd20b733d93cc385b + src/main/java/com/clerk/backend_api/models/components/Level.java: + id: 6762c7bcd8b6 + last_write_checksum: sha1:9be4e0d744cf3cd58554267384ea71c8c4401dda + pristine_git_object: fd72c2100539e46bb489449a0651fe154101c6ca src/main/java/com/clerk/backend_api/models/components/LifetimePaid.java: id: fcfda9810ba8 last_write_checksum: sha1:81aed52543ad72516a2a70435ba32745833e6f1e @@ -6620,6 +6672,18 @@ trackedFiles: id: 012331dca8e4 last_write_checksum: sha1:ec651af022d0608ea5f9152f73a989cbf9c4bb2d pristine_git_object: 956c7c0060a13245044e1b88dd5c61e88315a3ba + src/main/java/com/clerk/backend_api/models/components/Reverification.java: + id: 591ec7dc064d + last_write_checksum: sha1:d29778f58fdc09b9aedf6c7f1581def1f02f1178 + pristine_git_object: 2c6053e4faec8aa346ba8089a5b2c796a7eac0bb + src/main/java/com/clerk/backend_api/models/components/ReverificationObject.java: + id: 3788276d7a67 + last_write_checksum: sha1:0731f94282d9e328700d99b1c0903741ccf7b0f1 + pristine_git_object: b7961c910c105d77d7d3da10f2e3bc7c81c6b730 + src/main/java/com/clerk/backend_api/models/components/ReverificationStatus.java: + id: bab9cba14ac8 + last_write_checksum: sha1:0d153c175b9a7fbf3989c030033fc5ed296558be + pristine_git_object: c2e5b25b98a0202362f468fed647e907a10d5a91 src/main/java/com/clerk/backend_api/models/components/Role.java: id: 0824987a25bb last_write_checksum: sha1:a138ef731918b9aa1fb4633c241e90950e531f61 @@ -6760,14 +6824,18 @@ trackedFiles: id: 78f5f936d411 last_write_checksum: sha1:9f233584f6b73401ffa1926fbe6dff2168536b43 pristine_git_object: 9a785b47653b83f43a0377cb7e37a7ef68968c33 + src/main/java/com/clerk/backend_api/models/components/SCIMUserMetadata.java: + id: ba5ba69c125d + last_write_checksum: sha1:d8f7bf42a8af5e842b292cb461a97e61241dfc5c + pristine_git_object: 5892594354484f47e06b014fa09e98e6ab82edbb src/main/java/com/clerk/backend_api/models/components/Saml.java: id: 47564546a8f5 last_write_checksum: sha1:699784c9e31206f2ee92cae0fed32e0348e758bf pristine_git_object: f75b35326a853c27b07e80bb49c240b9de10f94e src/main/java/com/clerk/backend_api/models/components/Scim.java: id: 602a309b40a5 - last_write_checksum: sha1:22da09d383f0ac1e526c27a9b89e13d02c04cf55 - pristine_git_object: a7742dda15ce3f899fb8ef576cdad9654678e360 + last_write_checksum: sha1:f3b1e64b3a14e3349a1c529318d87adad7674d82 + pristine_git_object: eefd32c5876007c4236c4742b2f84e97f2f0d12d src/main/java/com/clerk/backend_api/models/components/Seats.java: id: a2587836532d last_write_checksum: sha1:aa244297c0e31aa8b51ee17e81a1bda8f221770d @@ -6950,12 +7018,24 @@ trackedFiles: pristine_git_object: 8d6abfb9306f4b8f50140816f566e9994c0f8fd0 src/main/java/com/clerk/backend_api/models/components/User.java: id: e0ba80043def - last_write_checksum: sha1:717b62ad1418f7c81d3e022f49b14f13722ea945 - pristine_git_object: 5eb46c43e43aed5d19c307e2273947a23b142e62 + last_write_checksum: sha1:1be4acbe2a51fb1bc6c03f0f1ed844ac88033d45 + pristine_git_object: fcbcb095c1562cb1b35084880271e6cad67d78df + src/main/java/com/clerk/backend_api/models/components/UserDirectory.java: + id: 0cd5454b8c2c + last_write_checksum: sha1:d3ea220fc5508a4228e6f5a42a8f2ce1a6e3667f + pristine_git_object: 32fb0b491bc3f10e5696d5bd5b4fb09cd56e4323 + src/main/java/com/clerk/backend_api/models/components/UserGroups.java: + id: 418a927dc0ac + last_write_checksum: sha1:00e1504015a4a1aeb8735a08b4d448c07f1dac15 + pristine_git_object: 8eac8c4e58c69af03e180a6767365faefe6c22ab src/main/java/com/clerk/backend_api/models/components/UserObject.java: id: 5efb9fe49895 last_write_checksum: sha1:3817019cf8043dcfae4bc45dc5a9d18da776a69a pristine_git_object: 3078267ce0952e8558a57c7a6069bdf9bf5df14e + src/main/java/com/clerk/backend_api/models/components/UserScimGroups.java: + id: a5bfef588530 + last_write_checksum: sha1:61e408b0fe04b5aef6915d5c16c2e9955b661658 + pristine_git_object: a5c43482877714548e754a8820b0b2ea4c1ebd29 src/main/java/com/clerk/backend_api/models/components/Verification.java: id: d4d7e8e73451 last_write_checksum: sha1:1574fc904487f746f6fce82b2252f668dede2e8a @@ -7630,8 +7710,8 @@ trackedFiles: pristine_git_object: 37c13897157bebe11b41f6d70ec0cbb94a8f1c87 src/main/java/com/clerk/backend_api/models/operations/AddDomainRequestBody.java: id: 1974d8ef569d - last_write_checksum: sha1:6dfab7bdf810041616b73a011c9f99a41f049761 - pristine_git_object: 62dcef05c8647a2d70ed93af7c86bee0486ac238 + last_write_checksum: sha1:1395a6f8d30809e228ab03dcb381232a380b5154 + pristine_git_object: 915ca0f04d32457151807c0308cdb46f64c1c5fc src/main/java/com/clerk/backend_api/models/operations/AddDomainRequestBuilder.java: id: 95e2055e00dd last_write_checksum: sha1:5f0d0f47251444d439ce6571471a512a9a003f8b @@ -8070,8 +8150,8 @@ trackedFiles: pristine_git_object: 1061e2595a5da26be7a5b76587fe25bf8c84bbd7 src/main/java/com/clerk/backend_api/models/operations/CreateOAuthApplicationRequestBody.java: id: 2deeec5de915 - last_write_checksum: sha1:c7a5a80a67c75f2687136d5db93a642575b96284 - pristine_git_object: 52aee8a26a0f842d4b70d9705c91d51e7cdaad52 + last_write_checksum: sha1:3d0244f7412950083924f335349f207fdf4347fa + pristine_git_object: f3995715858e2699b71bad197a4c6226f14e35aa src/main/java/com/clerk/backend_api/models/operations/CreateOAuthApplicationRequestBuilder.java: id: bef6f949dd98 last_write_checksum: sha1:fc078f1fd8faef859a891dbc1fa354fc8a8d64d7 @@ -8474,8 +8554,8 @@ trackedFiles: pristine_git_object: a410e048484c540925019015e469cb7bed6ec7d1 src/main/java/com/clerk/backend_api/models/operations/DeleteDomainRequest.java: id: 5da3e49c9139 - last_write_checksum: sha1:71bc78a6dd9e1cd16057ecf6d5e83ae60a6a0c05 - pristine_git_object: 5ac22d07573ee55c4b135cddaca4a446fbe9d28c + last_write_checksum: sha1:23a29f70e5cb5276f40e6d09260af6acad4125c9 + pristine_git_object: 7d67315e230c4585b0eb4044db52ba46fa1d82ab src/main/java/com/clerk/backend_api/models/operations/DeleteDomainRequestBuilder.java: id: bc29d51b7c02 last_write_checksum: sha1:28be0bc7bdfe772b53ef375d7553fd66dcb9742a @@ -9240,6 +9320,18 @@ trackedFiles: id: f5c299ea9c1a last_write_checksum: sha1:f9c8a65d42ce23f84820e0f18e45406432c662a7 pristine_git_object: eb75a4b518ad681d43933960346060ed8064ec60 + src/main/java/com/clerk/backend_api/models/operations/GetReverificationRequest.java: + id: 721e2878ffcb + last_write_checksum: sha1:6009352fdf3d98c716488816c4598b0140c9bc7d + pristine_git_object: 83baa25e83285b270f49e952577ba1953f392717 + src/main/java/com/clerk/backend_api/models/operations/GetReverificationRequestBuilder.java: + id: 908b30307f3d + last_write_checksum: sha1:2969abe60fab5942ffc26d4c8c4a760e6658942d + pristine_git_object: 851b07bb7735e9d72e97d013a9d98beed283839d + src/main/java/com/clerk/backend_api/models/operations/GetReverificationResponse.java: + id: c51f285e14c3 + last_write_checksum: sha1:e3706ad7f3048703dda0ad08f24b09b36bcc9b96 + pristine_git_object: a4701c55e5ec795ad573b20980b87c7bc9d578fd src/main/java/com/clerk/backend_api/models/operations/GetRoleSetRequest.java: id: 81163a774c0b last_write_checksum: sha1:6c34a2482cfb833f07f1b9754f9c0b5f0b4f4ab4 @@ -10146,8 +10238,8 @@ trackedFiles: pristine_git_object: 4bb8408e8893a2ed4b5adeaeb848e2b797407d7a src/main/java/com/clerk/backend_api/models/operations/ResponseBody1.java: id: 760a2dcf75ff - last_write_checksum: sha1:ed0725447175c05bea22e468004fb30eedf3c7e4 - pristine_git_object: d4b02e684ca16561f49e0f07ca8bf3e7384437e2 + last_write_checksum: sha1:cd8ab524f807605cc9eca16e24cae7b99a6790c4 + pristine_git_object: 59c76c23a4e3d8c37fa194f99b8cd9a5db0a5ddb src/main/java/com/clerk/backend_api/models/operations/ResponseBody2.java: id: 19c9f13e588a last_write_checksum: sha1:967b2df044399fa9ff9d398b959c09f671a7d686 @@ -10766,8 +10858,8 @@ trackedFiles: pristine_git_object: 85cc4394cbedd01e2922cebc81d002cb1a823823 src/main/java/com/clerk/backend_api/models/operations/UpdateOAuthApplicationRequestBody.java: id: 4c886e36fdc3 - last_write_checksum: sha1:112d8bbb9af67a17993b13d571197fea915520f1 - pristine_git_object: 0fbdfda158dda7df953e8e07520d9a3ac9ec2397 + last_write_checksum: sha1:866210d75822a50db96180d12cc3de1f8a28adcb + pristine_git_object: 3fabf50aa3666797e18d77553300abf56529af6c src/main/java/com/clerk/backend_api/models/operations/UpdateOAuthApplicationRequestBuilder.java: id: c1435499c8a7 last_write_checksum: sha1:c25a00011923398119ccefde5165a9c6f779facf @@ -11298,8 +11390,8 @@ trackedFiles: pristine_git_object: be438e72c4e9e84350e5a4eb498711c2259c966e src/main/java/com/clerk/backend_api/operations/AttemptPhoneNumberVerification.java: id: 251557c60a8d - last_write_checksum: sha1:963a6e0def93c96b4ad0defe22a0505ddc4ac1fa - pristine_git_object: de3b86f66f9f4c2b2060b4142683b86cae9cc9b2 + last_write_checksum: sha1:d4979dbf8499c655bbf4d4a1ffc6a8b41f7d4cee + pristine_git_object: 81c73574facef7d3dcf0e7cb5aa1d32d553a0b3c src/main/java/com/clerk/backend_api/operations/BanUser.java: id: d59d447fdda7 last_write_checksum: sha1:68e1c0c65e6ec979d4b6ad0e45837d4088e3ae65 @@ -11752,6 +11844,10 @@ trackedFiles: id: 6b1af89a5bd9 last_write_checksum: sha1:52a26dabf822199cb9382aa89a1154560df83856 pristine_git_object: 36381aa0a331a1272f0ac642d111b3469c58cd35 + src/main/java/com/clerk/backend_api/operations/GetReverification.java: + id: e06d4913885f + last_write_checksum: sha1:26c5cda69f4ec94d9eadbbe4b094f172660e5916 + pristine_git_object: 32fdcc42f469ee58cb4939bbcee80ac5b687b657 src/main/java/com/clerk/backend_api/operations/GetRoleSet.java: id: 1d648d0447ee last_write_checksum: sha1:a59674bd6676c949257afa251e1e49327ef9a1d0 @@ -15233,9 +15329,20 @@ examples: application/json: {"object": "directory_group_role_mapping", "id": "", "deleted": true} "400": application/json: {"errors": [{"message": "", "long_message": "", "code": ""}]} + GetReverification: + speakeasy-default-get-reverification: + parameters: + path: + session_id: "" + reverification_id: "" + responses: + "200": + application/json: {"object": "reverification", "id": "", "session_id": "", "user_id": "", "level": "multi_factor", "status": "needs_second_factor", "first_factor_verified_at": 981024, "second_factor_verified_at": 327447, "created_at": 743811, "updated_at": 518936} + "400": + application/json: {"errors": [{"message": "", "long_message": "", "code": ""}]} examplesVersion: 1.0.2 generatedTests: {} -releaseNotes: "## Java SDK Changes:\n* `clerk.users.listBiometricCredentials()`: **Added**\n* `clerk.users.revokeBiometricCredential()`: **Added**\n* `clerk.billing.applySubscriptionItemDiscount()`: **Added**\n* `clerk.billing.removeSubscriptionItemDiscount()`: **Added**\n* `clerk.directories.list()`: **Added**\n* `clerk.directories.create()`: **Added**\n* `clerk.directories.get()`: **Added**\n* `clerk.directories.update()`: **Added**\n* `clerk.directories.delete()`: **Added**\n* `clerk.directories.rotateApiKey()`: **Added**\n* `clerk.directories.listGroupRoleMappings()`: **Added**\n* `clerk.directories.createGroupRoleMapping()`: **Added**\n* `clerk.directories.replaceGroupRoleMappings()`: **Added**\n* `clerk.directories.deleteGroupRoleMapping()`: **Added**\n* `clerk.users.list()`: \n * `request.startingAfter` **Added**\n * `response.[].organizationMemberships[].organization.selfServeSsoEnabled` **Added**\n* `clerk.users.create()`: \n * `request.skipRestrictionChecks` **Added**\n * `response.organizationMemberships[].organization.selfServeSsoEnabled` **Added**\n* `clerk.users.get()`: `response.organizationMemberships[].organization.selfServeSsoEnabled` **Added**\n* `clerk.users.update()`: `response.organizationMemberships[].organization.selfServeSsoEnabled` **Added**\n* `clerk.users.ban()`: `response.organizationMemberships[].organization.selfServeSsoEnabled` **Added**\n* `clerk.users.unban()`: `response.organizationMemberships[].organization.selfServeSsoEnabled` **Added**\n* `clerk.users.bulkBan()`: `response.[].organizationMemberships[].organization.selfServeSsoEnabled` **Added**\n* `clerk.users.bulkUnban()`: `response.[].organizationMemberships[].organization.selfServeSsoEnabled` **Added**\n* `clerk.users.lock()`: `response.organizationMemberships[].organization.selfServeSsoEnabled` **Added**\n* `clerk.users.unlock()`: `response.organizationMemberships[].organization.selfServeSsoEnabled` **Added**\n* `clerk.users.setProfileImage()`: `response.organizationMemberships[].organization.selfServeSsoEnabled` **Added**\n* `clerk.users.deleteProfileImage()`: `response.organizationMemberships[].organization.selfServeSsoEnabled` **Added**\n* `clerk.users.updateMetadata()`: `response.organizationMemberships[].organization.selfServeSsoEnabled` **Added**\n* `clerk.users.replaceMetadata()`: `response.organizationMemberships[].organization.selfServeSsoEnabled` **Added**\n* `clerk.users.getOrganizationMemberships()`: `response.data[].organization.selfServeSsoEnabled` **Added**\n* `clerk.users.removePassword()`: `response.organizationMemberships[].organization.selfServeSsoEnabled` **Added**\n* `clerk.users.listTrustedDevices()`: **Deprecated**\n* `clerk.users.revokeTrustedDevice()`: **Deprecated**\n* `clerk.users.setPasswordCompromised()`: `response.organizationMemberships[].organization.selfServeSsoEnabled` **Added**\n* `clerk.users.unsetPasswordCompromised()`: `response.organizationMemberships[].organization.selfServeSsoEnabled` **Added**\n* `clerk.users.getInstanceOrganizationMemberships()`: `response.data[].organization.selfServeSsoEnabled` **Added**\n* `clerk.actorTokens.create()`: `error.status[403]` **Added**\n* `clerk.domains.list()`: `response.data[].dnsTargets` **Added**\n* `clerk.domains.add()`: `response.dnsTargets` **Added**\n* `clerk.domains.update()`: `response.dnsTargets` **Added**\n* `clerk.instanceSettings.get()`: `response` **Changed**\n* `clerk.instanceSettings.update()`: `request` **Changed**\n* `clerk.instanceSettings.getOAuthApplicationSettings()`: `response` **Changed**\n* `clerk.instanceSettings.updateOAuthApplicationSettings()`: \n * `request` **Changed**\n * `response` **Changed**\n* `clerk.instanceSettings.getInstanceProtect()`: `response` **Changed**\n* `clerk.instanceSettings.updateInstanceProtect()`: `response` **Changed**\n* `clerk.organizations.list()`: `response.data[].selfServeSsoEnabled` **Added**\n* `clerk.organizations.create()`: `response.selfServeSsoEnabled` **Added**\n* `clerk.organizations.get()`: `response.selfServeSsoEnabled` **Added**\n* `clerk.organizations.update()`: \n * `requestBody.selfServeSsoEnabled` **Added**\n * `response.selfServeSsoEnabled` **Added**\n* `clerk.organizations.mergeMetadata()`: `response.selfServeSsoEnabled` **Added**\n* `clerk.organizations.replaceMetadata()`: `response.selfServeSsoEnabled` **Added**\n* `clerk.organizations.uploadLogo()`: `response.selfServeSsoEnabled` **Added**\n* `clerk.organizations.deleteLogo()`: `response.selfServeSsoEnabled` **Added**\n* `clerk.organizationMemberships.create()`: `response.organization.selfServeSsoEnabled` **Added**\n* `clerk.organizationMemberships.list()`: `response.data[].organization.selfServeSsoEnabled` **Added**\n* `clerk.organizationMemberships.update()`: `response.organization.selfServeSsoEnabled` **Added**\n* `clerk.organizationMemberships.delete()`: `response.organization.selfServeSsoEnabled` **Added**\n* `clerk.organizationMemberships.updateMetadata()`: `response.organization.selfServeSsoEnabled` **Added**\n* `clerk.oauthApplications.list()`: `response.data[].deviceAuthorizationGrantEnabled` **Added**\n* `clerk.oauthApplications.create()`: \n * `request.deviceAuthorizationGrantEnabled` **Added**\n * `response.deviceAuthorizationGrantEnabled` **Added**\n* `clerk.oauthApplications.get()`: `response.deviceAuthorizationGrantEnabled` **Added**\n* `clerk.oauthApplications.update()`: \n * `requestBody` **Changed**\n * `response.deviceAuthorizationGrantEnabled` **Added**\n* `clerk.oauthApplications.uploadLogo()`: `response.deviceAuthorizationGrantEnabled` **Added**\n* `clerk.oauthApplications.rotateSecret()`: `response.deviceAuthorizationGrantEnabled` **Added**\n* `clerk.enterpriseConnections.list()`: `response.data[].customAttributes[].directoryPath` **Added**\n* `clerk.enterpriseConnections.create()`: \n * `request.customAttributes[].directoryPath` **Added**\n * `response.customAttributes[].directoryPath` **Added**\n* `clerk.enterpriseConnections.get()`: `response.customAttributes[].directoryPath` **Added**\n* `clerk.enterpriseConnections.update()`: \n * `requestBody.customAttributes[].directoryPath` **Added**\n * `response.customAttributes[].directoryPath` **Added**\n* `clerk.scimDirectories.list()`: `response.data[].customAttributes[].directoryPath` **Added**\n* `clerk.scimDirectories.create()`: `response.customAttributes[].directoryPath` **Added**\n* `clerk.scimDirectories.get()`: `response.customAttributes[].directoryPath` **Added**\n* `clerk.scimDirectories.update()`: `response.customAttributes[].directoryPath` **Added**\n* `clerk.scimDirectories.rotateApiKey()`: \n * `response.customAttributes[].directoryPath` **Added**\n * `error.status[422]` **Added**\n* `clerk.scimDirectories.listGroupRoleMappings()`: `response.data[]` **Changed**\n* `clerk.scimDirectories.createGroupRoleMapping()`: `response` **Changed**\n* `clerk.scimDirectories.replaceGroupRoleMappings()`: `response.data[]` **Changed**\n" +releaseNotes: "## Java SDK Changes:\n* `clerk.sessions.getReverification()`: **Added**\n* `clerk.phoneNumbers.attemptVerification()`: `error` **Changed**\n* `clerk.users.list()`: `response.[]` **Changed**\n* `clerk.users.create()`: `response` **Changed**\n* `clerk.users.get()`: `response` **Changed**\n* `clerk.users.update()`: `response` **Changed**\n* `clerk.users.ban()`: `response` **Changed**\n* `clerk.users.unban()`: `response` **Changed**\n* `clerk.users.bulkBan()`: `response.[]` **Changed**\n* `clerk.users.bulkUnban()`: `response.[]` **Changed**\n* `clerk.users.lock()`: `response` **Changed**\n* `clerk.users.unlock()`: `response` **Changed**\n* `clerk.users.setProfileImage()`: `response` **Changed**\n* `clerk.users.deleteProfileImage()`: `response` **Changed**\n* `clerk.users.updateMetadata()`: `response` **Changed**\n* `clerk.users.replaceMetadata()`: `response` **Changed**\n* `clerk.users.removePassword()`: `response` **Changed**\n* `clerk.users.setPasswordCompromised()`: `response` **Changed**\n* `clerk.users.unsetPasswordCompromised()`: `response` **Changed**\n* `clerk.domains.add()`: \n * `request.isSatellite` **Changed**\n* `clerk.oauthAccessTokens.verify()`: `response.union(1).aud` **Added**\n" generatedFiles: - .gitattributes - USAGE.md diff --git a/.speakeasy/gen.yaml b/.speakeasy/gen.yaml index 3f086796..d74be145 100755 --- a/.speakeasy/gen.yaml +++ b/.speakeasy/gen.yaml @@ -29,7 +29,7 @@ generation: generateNewTests: false skipResponseBodyAssertions: false java: - version: 6.1.0 + version: 6.1.1 additionalDependencies: [] additionalPlugins: [] artifactID: backend-api diff --git a/.speakeasy/workflow.lock b/.speakeasy/workflow.lock index 4caf300f..00b9d5c8 100644 --- a/.speakeasy/workflow.lock +++ b/.speakeasy/workflow.lock @@ -1,9 +1,9 @@ -speakeasyVersion: 1.797.0 +speakeasyVersion: 1.798.0 sources: clerk-java-sdk: sourceNamespace: clerk-java-sdk - sourceRevisionDigest: sha256:ec9218598a78ea67234fb0bf92b0d68146da3ea2fb7075f0ab42db482fa1d829 - sourceBlobDigest: sha256:621774b0be158b14c14a9ec2b083d73e85e6643f81b64c9f011be27a694506eb + sourceRevisionDigest: sha256:3e81fc7955c44254605f6d3775360a4b7240784ef33b347a95774180d3de36df + sourceBlobDigest: sha256:d00f1d0f528cdad594bf657503cb9134ce81a46b3d0f3c43329c8956125c6355 tags: - latest - "2026-05-12" @@ -11,10 +11,10 @@ targets: clerk-java: source: clerk-java-sdk sourceNamespace: clerk-java-sdk - sourceRevisionDigest: sha256:ec9218598a78ea67234fb0bf92b0d68146da3ea2fb7075f0ab42db482fa1d829 - sourceBlobDigest: sha256:621774b0be158b14c14a9ec2b083d73e85e6643f81b64c9f011be27a694506eb + sourceRevisionDigest: sha256:3e81fc7955c44254605f6d3775360a4b7240784ef33b347a95774180d3de36df + sourceBlobDigest: sha256:d00f1d0f528cdad594bf657503cb9134ce81a46b3d0f3c43329c8956125c6355 codeSamplesNamespace: clerk-java-sdk-code-samples - codeSamplesRevisionDigest: sha256:cb564ae7e0be4ada9a4e8469e037ae8ee794c4b7f655a74fa2136ccbc5dad0a9 + codeSamplesRevisionDigest: sha256:c7d57ae1746a103a4a93a0b86389907045b6e3563a24636884fa21f65ef5690a my-first-target: source: clerk-java-sdk sourceNamespace: clerk-java-sdk diff --git a/README.md b/README.md index 4c954147..c23af741 100644 --- a/README.md +++ b/README.md @@ -53,7 +53,7 @@ The samples below show how a published SDK artifact is used: Gradle: ```groovy -implementation 'com.clerk:backend-api:6.1.0' +implementation 'com.clerk:backend-api:6.1.1' ``` Maven: @@ -61,7 +61,7 @@ Maven: com.clerk backend-api - 6.1.0 + 6.1.1 ``` @@ -292,7 +292,7 @@ public class MachineAuthentication { * [list](docs/sdks/domains/README.md#list) - List all instance domains * [add](docs/sdks/domains/README.md#add) - Add a domain -* [delete](docs/sdks/domains/README.md#delete) - Delete a satellite domain +* [delete](docs/sdks/domains/README.md#delete) - Delete a domain * [update](docs/sdks/domains/README.md#update) - Update a domain ### [EmailAddresses](docs/sdks/emailaddresses/README.md) @@ -516,6 +516,7 @@ public class MachineAuthentication { * [create](docs/sdks/sessions/README.md#create) - Create a new active session * [get](docs/sdks/sessions/README.md#get) - Retrieve a session * [refresh](docs/sdks/sessions/README.md#refresh) - Refresh a session +* [getReverification](docs/sdks/sessions/README.md#getreverification) - Retrieve a reverification * [revoke](docs/sdks/sessions/README.md#revoke) - Revoke a session * [createToken](docs/sdks/sessions/README.md#createtoken) - Create a session token * [createTokenFromTemplate](docs/sdks/sessions/README.md#createtokenfromtemplate) - Create a session token from a JWT template @@ -772,41 +773,41 @@ public class Application { many more subclasses in the JDK platform). **Inherit from [`ClerkError`](./src/main/java/models/errors/ClerkError.java)**: -* [`com.clerk.backend_api.models.errors.CreateAdminPortalLinkTokenResponseBody`](./src/main/java/models/errors/com.clerk.backend_api.models.errors.CreateAdminPortalLinkTokenResponseBody.java): 400 Bad Request. Status code `400`. Applicable to 1 of 251 methods.* -* [`com.clerk.backend_api.models.errors.RevokeAdminPortalLinkTokenResponseBody`](./src/main/java/models/errors/com.clerk.backend_api.models.errors.RevokeAdminPortalLinkTokenResponseBody.java): 400 Bad Request. Status code `400`. Applicable to 1 of 251 methods.* -* [`com.clerk.backend_api.models.errors.CreateApiKeyResponseBody`](./src/main/java/models/errors/com.clerk.backend_api.models.errors.CreateApiKeyResponseBody.java): 400 Bad Request. Status code `400`. Applicable to 1 of 251 methods.* -* [`com.clerk.backend_api.models.errors.GetApiKeysResponseBody`](./src/main/java/models/errors/com.clerk.backend_api.models.errors.GetApiKeysResponseBody.java): 400 Bad Request. Status code `400`. Applicable to 1 of 251 methods.* -* [`com.clerk.backend_api.models.errors.GetApiKeyResponseBody`](./src/main/java/models/errors/com.clerk.backend_api.models.errors.GetApiKeyResponseBody.java): 400 Bad Request. Status code `400`. Applicable to 1 of 251 methods.* -* [`com.clerk.backend_api.models.errors.UpdateApiKeyResponseBody`](./src/main/java/models/errors/com.clerk.backend_api.models.errors.UpdateApiKeyResponseBody.java): 400 Bad Request. Status code `400`. Applicable to 1 of 251 methods.* -* [`com.clerk.backend_api.models.errors.DeleteApiKeyResponseBody`](./src/main/java/models/errors/com.clerk.backend_api.models.errors.DeleteApiKeyResponseBody.java): 400 Bad Request. Status code `400`. Applicable to 1 of 251 methods.* -* [`com.clerk.backend_api.models.errors.GetApiKeySecretResponseBody`](./src/main/java/models/errors/com.clerk.backend_api.models.errors.GetApiKeySecretResponseBody.java): 400 Bad Request. Status code `400`. Applicable to 1 of 251 methods.* -* [`com.clerk.backend_api.models.errors.RevokeApiKeyResponseBody`](./src/main/java/models/errors/com.clerk.backend_api.models.errors.RevokeApiKeyResponseBody.java): 400 Bad Request. Status code `400`. Applicable to 1 of 251 methods.* -* [`com.clerk.backend_api.models.errors.VerifyApiKeyResponseBody`](./src/main/java/models/errors/com.clerk.backend_api.models.errors.VerifyApiKeyResponseBody.java): 400 Bad Request. Status code `400`. Applicable to 1 of 251 methods.* -* [`com.clerk.backend_api.models.errors.CreateM2MTokenResponseBody`](./src/main/java/models/errors/com.clerk.backend_api.models.errors.CreateM2MTokenResponseBody.java): 400 Bad Request. Status code `400`. Applicable to 1 of 251 methods.* -* [`com.clerk.backend_api.models.errors.GetM2MTokensResponseBody`](./src/main/java/models/errors/com.clerk.backend_api.models.errors.GetM2MTokensResponseBody.java): 400 Bad Request. Status code `400`. Applicable to 1 of 251 methods.* -* [`com.clerk.backend_api.models.errors.RevokeM2MTokenResponseBody`](./src/main/java/models/errors/com.clerk.backend_api.models.errors.RevokeM2MTokenResponseBody.java): 400 Bad Request. Status code `400`. Applicable to 1 of 251 methods.* -* [`com.clerk.backend_api.models.errors.VerifyM2MTokenResponseBody`](./src/main/java/models/errors/com.clerk.backend_api.models.errors.VerifyM2MTokenResponseBody.java): 400 Bad Request. Status code `400`. Applicable to 1 of 251 methods.* -* [`com.clerk.backend_api.models.errors.VerifyOAuthAccessTokenResponseBody`](./src/main/java/models/errors/com.clerk.backend_api.models.errors.VerifyOAuthAccessTokenResponseBody.java): 400 Bad Request. Status code `400`. Applicable to 1 of 251 methods.* -* [`com.clerk.backend_api.models.errors.CreateAdminPortalLinkTokenAdminPortalLinkTokensResponseBody`](./src/main/java/models/errors/com.clerk.backend_api.models.errors.CreateAdminPortalLinkTokenAdminPortalLinkTokensResponseBody.java): 401 Unauthorized. Status code `401`. Applicable to 1 of 251 methods.* -* [`com.clerk.backend_api.models.errors.RevokeAdminPortalLinkTokenAdminPortalLinkTokensResponseBody`](./src/main/java/models/errors/com.clerk.backend_api.models.errors.RevokeAdminPortalLinkTokenAdminPortalLinkTokensResponseBody.java): 401 Unauthorized. Status code `401`. Applicable to 1 of 251 methods.* -* [`com.clerk.backend_api.models.errors.CreateAdminPortalLinkTokenAdminPortalLinkTokensResponseResponseBody`](./src/main/java/models/errors/com.clerk.backend_api.models.errors.CreateAdminPortalLinkTokenAdminPortalLinkTokensResponseResponseBody.java): 403 Forbidden. Status code `403`. Applicable to 1 of 251 methods.* -* [`com.clerk.backend_api.models.errors.RevokeAdminPortalLinkTokenAdminPortalLinkTokensResponseResponseBody`](./src/main/java/models/errors/com.clerk.backend_api.models.errors.RevokeAdminPortalLinkTokenAdminPortalLinkTokensResponseResponseBody.java): 403 Forbidden. Status code `403`. Applicable to 1 of 251 methods.* -* [`com.clerk.backend_api.models.errors.GetM2MTokensM2mResponseBody`](./src/main/java/models/errors/com.clerk.backend_api.models.errors.GetM2MTokensM2mResponseBody.java): 403 Forbidden. Status code `403`. Applicable to 1 of 251 methods.* -* [`com.clerk.backend_api.models.errors.RevokeAdminPortalLinkTokenAdminPortalLinkTokensResponse404ResponseBody`](./src/main/java/models/errors/com.clerk.backend_api.models.errors.RevokeAdminPortalLinkTokenAdminPortalLinkTokensResponse404ResponseBody.java): 404 Not Found. Status code `404`. Applicable to 1 of 251 methods.* -* [`com.clerk.backend_api.models.errors.GetAPIKeysAPIKeysResponseBody`](./src/main/java/models/errors/com.clerk.backend_api.models.errors.GetAPIKeysAPIKeysResponseBody.java): 404 Not Found. Status code `404`. Applicable to 1 of 251 methods.* -* [`com.clerk.backend_api.models.errors.GetAPIKeyAPIKeysResponseBody`](./src/main/java/models/errors/com.clerk.backend_api.models.errors.GetAPIKeyAPIKeysResponseBody.java): 404 Not Found. Status code `404`. Applicable to 1 of 251 methods.* -* [`com.clerk.backend_api.models.errors.UpdateAPIKeyAPIKeysResponseBody`](./src/main/java/models/errors/com.clerk.backend_api.models.errors.UpdateAPIKeyAPIKeysResponseBody.java): 404 Not Found. Status code `404`. Applicable to 1 of 251 methods.* -* [`com.clerk.backend_api.models.errors.DeleteAPIKeyAPIKeysResponseBody`](./src/main/java/models/errors/com.clerk.backend_api.models.errors.DeleteAPIKeyAPIKeysResponseBody.java): 404 Not Found. Status code `404`. Applicable to 1 of 251 methods.* -* [`com.clerk.backend_api.models.errors.GetAPIKeySecretAPIKeysResponseBody`](./src/main/java/models/errors/com.clerk.backend_api.models.errors.GetAPIKeySecretAPIKeysResponseBody.java): 404 Not Found. Status code `404`. Applicable to 1 of 251 methods.* -* [`com.clerk.backend_api.models.errors.RevokeAPIKeyAPIKeysResponseBody`](./src/main/java/models/errors/com.clerk.backend_api.models.errors.RevokeAPIKeyAPIKeysResponseBody.java): 404 Not Found. Status code `404`. Applicable to 1 of 251 methods.* -* [`com.clerk.backend_api.models.errors.VerifyAPIKeyAPIKeysResponseBody`](./src/main/java/models/errors/com.clerk.backend_api.models.errors.VerifyAPIKeyAPIKeysResponseBody.java): 404 Not Found. Status code `404`. Applicable to 1 of 251 methods.* -* [`com.clerk.backend_api.models.errors.GetM2MTokensM2mResponseResponseBody`](./src/main/java/models/errors/com.clerk.backend_api.models.errors.GetM2MTokensM2mResponseResponseBody.java): 404 Not Found. Status code `404`. Applicable to 1 of 251 methods.* -* [`com.clerk.backend_api.models.errors.RevokeM2MTokenM2mResponseBody`](./src/main/java/models/errors/com.clerk.backend_api.models.errors.RevokeM2MTokenM2mResponseBody.java): 404 Not Found. Status code `404`. Applicable to 1 of 251 methods.* -* [`com.clerk.backend_api.models.errors.VerifyM2MTokenM2mResponseBody`](./src/main/java/models/errors/com.clerk.backend_api.models.errors.VerifyM2MTokenM2mResponseBody.java): 404 Not Found. Status code `404`. Applicable to 1 of 251 methods.* -* [`com.clerk.backend_api.models.errors.VerifyOAuthAccessTokenOauthAccessTokensResponseBody`](./src/main/java/models/errors/com.clerk.backend_api.models.errors.VerifyOAuthAccessTokenOauthAccessTokensResponseBody.java): 404 Not Found. Status code `404`. Applicable to 1 of 251 methods.* -* [`com.clerk.backend_api.models.errors.CreateAdminPortalLinkTokenAdminPortalLinkTokensResponse409ResponseBody`](./src/main/java/models/errors/com.clerk.backend_api.models.errors.CreateAdminPortalLinkTokenAdminPortalLinkTokensResponse409ResponseBody.java): 409 Conflict. Status code `409`. Applicable to 1 of 251 methods.* -* [`com.clerk.backend_api.models.errors.CreateAPIKeyAPIKeysResponseBody`](./src/main/java/models/errors/com.clerk.backend_api.models.errors.CreateAPIKeyAPIKeysResponseBody.java): 409 Conflict. Status code `409`. Applicable to 1 of 251 methods.* -* [`com.clerk.backend_api.models.errors.CreateM2MTokenM2mResponseBody`](./src/main/java/models/errors/com.clerk.backend_api.models.errors.CreateM2MTokenM2mResponseBody.java): 409 Conflict. Status code `409`. Applicable to 1 of 251 methods.* +* [`com.clerk.backend_api.models.errors.CreateAdminPortalLinkTokenResponseBody`](./src/main/java/models/errors/com.clerk.backend_api.models.errors.CreateAdminPortalLinkTokenResponseBody.java): 400 Bad Request. Status code `400`. Applicable to 1 of 252 methods.* +* [`com.clerk.backend_api.models.errors.RevokeAdminPortalLinkTokenResponseBody`](./src/main/java/models/errors/com.clerk.backend_api.models.errors.RevokeAdminPortalLinkTokenResponseBody.java): 400 Bad Request. Status code `400`. Applicable to 1 of 252 methods.* +* [`com.clerk.backend_api.models.errors.CreateApiKeyResponseBody`](./src/main/java/models/errors/com.clerk.backend_api.models.errors.CreateApiKeyResponseBody.java): 400 Bad Request. Status code `400`. Applicable to 1 of 252 methods.* +* [`com.clerk.backend_api.models.errors.GetApiKeysResponseBody`](./src/main/java/models/errors/com.clerk.backend_api.models.errors.GetApiKeysResponseBody.java): 400 Bad Request. Status code `400`. Applicable to 1 of 252 methods.* +* [`com.clerk.backend_api.models.errors.GetApiKeyResponseBody`](./src/main/java/models/errors/com.clerk.backend_api.models.errors.GetApiKeyResponseBody.java): 400 Bad Request. Status code `400`. Applicable to 1 of 252 methods.* +* [`com.clerk.backend_api.models.errors.UpdateApiKeyResponseBody`](./src/main/java/models/errors/com.clerk.backend_api.models.errors.UpdateApiKeyResponseBody.java): 400 Bad Request. Status code `400`. Applicable to 1 of 252 methods.* +* [`com.clerk.backend_api.models.errors.DeleteApiKeyResponseBody`](./src/main/java/models/errors/com.clerk.backend_api.models.errors.DeleteApiKeyResponseBody.java): 400 Bad Request. Status code `400`. Applicable to 1 of 252 methods.* +* [`com.clerk.backend_api.models.errors.GetApiKeySecretResponseBody`](./src/main/java/models/errors/com.clerk.backend_api.models.errors.GetApiKeySecretResponseBody.java): 400 Bad Request. Status code `400`. Applicable to 1 of 252 methods.* +* [`com.clerk.backend_api.models.errors.RevokeApiKeyResponseBody`](./src/main/java/models/errors/com.clerk.backend_api.models.errors.RevokeApiKeyResponseBody.java): 400 Bad Request. Status code `400`. Applicable to 1 of 252 methods.* +* [`com.clerk.backend_api.models.errors.VerifyApiKeyResponseBody`](./src/main/java/models/errors/com.clerk.backend_api.models.errors.VerifyApiKeyResponseBody.java): 400 Bad Request. Status code `400`. Applicable to 1 of 252 methods.* +* [`com.clerk.backend_api.models.errors.CreateM2MTokenResponseBody`](./src/main/java/models/errors/com.clerk.backend_api.models.errors.CreateM2MTokenResponseBody.java): 400 Bad Request. Status code `400`. Applicable to 1 of 252 methods.* +* [`com.clerk.backend_api.models.errors.GetM2MTokensResponseBody`](./src/main/java/models/errors/com.clerk.backend_api.models.errors.GetM2MTokensResponseBody.java): 400 Bad Request. Status code `400`. Applicable to 1 of 252 methods.* +* [`com.clerk.backend_api.models.errors.RevokeM2MTokenResponseBody`](./src/main/java/models/errors/com.clerk.backend_api.models.errors.RevokeM2MTokenResponseBody.java): 400 Bad Request. Status code `400`. Applicable to 1 of 252 methods.* +* [`com.clerk.backend_api.models.errors.VerifyM2MTokenResponseBody`](./src/main/java/models/errors/com.clerk.backend_api.models.errors.VerifyM2MTokenResponseBody.java): 400 Bad Request. Status code `400`. Applicable to 1 of 252 methods.* +* [`com.clerk.backend_api.models.errors.VerifyOAuthAccessTokenResponseBody`](./src/main/java/models/errors/com.clerk.backend_api.models.errors.VerifyOAuthAccessTokenResponseBody.java): 400 Bad Request. Status code `400`. Applicable to 1 of 252 methods.* +* [`com.clerk.backend_api.models.errors.CreateAdminPortalLinkTokenAdminPortalLinkTokensResponseBody`](./src/main/java/models/errors/com.clerk.backend_api.models.errors.CreateAdminPortalLinkTokenAdminPortalLinkTokensResponseBody.java): 401 Unauthorized. Status code `401`. Applicable to 1 of 252 methods.* +* [`com.clerk.backend_api.models.errors.RevokeAdminPortalLinkTokenAdminPortalLinkTokensResponseBody`](./src/main/java/models/errors/com.clerk.backend_api.models.errors.RevokeAdminPortalLinkTokenAdminPortalLinkTokensResponseBody.java): 401 Unauthorized. Status code `401`. Applicable to 1 of 252 methods.* +* [`com.clerk.backend_api.models.errors.CreateAdminPortalLinkTokenAdminPortalLinkTokensResponseResponseBody`](./src/main/java/models/errors/com.clerk.backend_api.models.errors.CreateAdminPortalLinkTokenAdminPortalLinkTokensResponseResponseBody.java): 403 Forbidden. Status code `403`. Applicable to 1 of 252 methods.* +* [`com.clerk.backend_api.models.errors.RevokeAdminPortalLinkTokenAdminPortalLinkTokensResponseResponseBody`](./src/main/java/models/errors/com.clerk.backend_api.models.errors.RevokeAdminPortalLinkTokenAdminPortalLinkTokensResponseResponseBody.java): 403 Forbidden. Status code `403`. Applicable to 1 of 252 methods.* +* [`com.clerk.backend_api.models.errors.GetM2MTokensM2mResponseBody`](./src/main/java/models/errors/com.clerk.backend_api.models.errors.GetM2MTokensM2mResponseBody.java): 403 Forbidden. Status code `403`. Applicable to 1 of 252 methods.* +* [`com.clerk.backend_api.models.errors.RevokeAdminPortalLinkTokenAdminPortalLinkTokensResponse404ResponseBody`](./src/main/java/models/errors/com.clerk.backend_api.models.errors.RevokeAdminPortalLinkTokenAdminPortalLinkTokensResponse404ResponseBody.java): 404 Not Found. Status code `404`. Applicable to 1 of 252 methods.* +* [`com.clerk.backend_api.models.errors.GetAPIKeysAPIKeysResponseBody`](./src/main/java/models/errors/com.clerk.backend_api.models.errors.GetAPIKeysAPIKeysResponseBody.java): 404 Not Found. Status code `404`. Applicable to 1 of 252 methods.* +* [`com.clerk.backend_api.models.errors.GetAPIKeyAPIKeysResponseBody`](./src/main/java/models/errors/com.clerk.backend_api.models.errors.GetAPIKeyAPIKeysResponseBody.java): 404 Not Found. Status code `404`. Applicable to 1 of 252 methods.* +* [`com.clerk.backend_api.models.errors.UpdateAPIKeyAPIKeysResponseBody`](./src/main/java/models/errors/com.clerk.backend_api.models.errors.UpdateAPIKeyAPIKeysResponseBody.java): 404 Not Found. Status code `404`. Applicable to 1 of 252 methods.* +* [`com.clerk.backend_api.models.errors.DeleteAPIKeyAPIKeysResponseBody`](./src/main/java/models/errors/com.clerk.backend_api.models.errors.DeleteAPIKeyAPIKeysResponseBody.java): 404 Not Found. Status code `404`. Applicable to 1 of 252 methods.* +* [`com.clerk.backend_api.models.errors.GetAPIKeySecretAPIKeysResponseBody`](./src/main/java/models/errors/com.clerk.backend_api.models.errors.GetAPIKeySecretAPIKeysResponseBody.java): 404 Not Found. Status code `404`. Applicable to 1 of 252 methods.* +* [`com.clerk.backend_api.models.errors.RevokeAPIKeyAPIKeysResponseBody`](./src/main/java/models/errors/com.clerk.backend_api.models.errors.RevokeAPIKeyAPIKeysResponseBody.java): 404 Not Found. Status code `404`. Applicable to 1 of 252 methods.* +* [`com.clerk.backend_api.models.errors.VerifyAPIKeyAPIKeysResponseBody`](./src/main/java/models/errors/com.clerk.backend_api.models.errors.VerifyAPIKeyAPIKeysResponseBody.java): 404 Not Found. Status code `404`. Applicable to 1 of 252 methods.* +* [`com.clerk.backend_api.models.errors.GetM2MTokensM2mResponseResponseBody`](./src/main/java/models/errors/com.clerk.backend_api.models.errors.GetM2MTokensM2mResponseResponseBody.java): 404 Not Found. Status code `404`. Applicable to 1 of 252 methods.* +* [`com.clerk.backend_api.models.errors.RevokeM2MTokenM2mResponseBody`](./src/main/java/models/errors/com.clerk.backend_api.models.errors.RevokeM2MTokenM2mResponseBody.java): 404 Not Found. Status code `404`. Applicable to 1 of 252 methods.* +* [`com.clerk.backend_api.models.errors.VerifyM2MTokenM2mResponseBody`](./src/main/java/models/errors/com.clerk.backend_api.models.errors.VerifyM2MTokenM2mResponseBody.java): 404 Not Found. Status code `404`. Applicable to 1 of 252 methods.* +* [`com.clerk.backend_api.models.errors.VerifyOAuthAccessTokenOauthAccessTokensResponseBody`](./src/main/java/models/errors/com.clerk.backend_api.models.errors.VerifyOAuthAccessTokenOauthAccessTokensResponseBody.java): 404 Not Found. Status code `404`. Applicable to 1 of 252 methods.* +* [`com.clerk.backend_api.models.errors.CreateAdminPortalLinkTokenAdminPortalLinkTokensResponse409ResponseBody`](./src/main/java/models/errors/com.clerk.backend_api.models.errors.CreateAdminPortalLinkTokenAdminPortalLinkTokensResponse409ResponseBody.java): 409 Conflict. Status code `409`. Applicable to 1 of 252 methods.* +* [`com.clerk.backend_api.models.errors.CreateAPIKeyAPIKeysResponseBody`](./src/main/java/models/errors/com.clerk.backend_api.models.errors.CreateAPIKeyAPIKeysResponseBody.java): 409 Conflict. Status code `409`. Applicable to 1 of 252 methods.* +* [`com.clerk.backend_api.models.errors.CreateM2MTokenM2mResponseBody`](./src/main/java/models/errors/com.clerk.backend_api.models.errors.CreateM2MTokenM2mResponseBody.java): 409 Conflict. Status code `409`. Applicable to 1 of 252 methods.* diff --git a/RELEASES.md b/RELEASES.md index 71711f64..345c78bc 100644 --- a/RELEASES.md +++ b/RELEASES.md @@ -448,4 +448,14 @@ Based on: ### Generated - [java v6.1.0] . ### Releases -- [Maven Central v6.1.0] https://central.sonatype.com/artifact/com.clerk/backend-api/6.1.0 - . \ No newline at end of file +- [Maven Central v6.1.0] https://central.sonatype.com/artifact/com.clerk/backend-api/6.1.0 - . + +## 2026-09-21 00:16:33 +### Changes +Based on: +- OpenAPI Doc +- Speakeasy CLI 1.798.0 (2.938.0) https://github.com/speakeasy-api/speakeasy +### Generated +- [java v6.1.1] . +### Releases +- [Maven Central v6.1.1] https://central.sonatype.com/artifact/com.clerk/backend-api/6.1.1 - . \ No newline at end of file diff --git a/docs/models/components/BillingStatement.md b/docs/models/components/BillingStatement.md index 0de53e97..dfec04a2 100644 --- a/docs/models/components/BillingStatement.md +++ b/docs/models/components/BillingStatement.md @@ -12,4 +12,4 @@ | `payer` | [CommercePayerResponse](../../models/components/CommercePayerResponse.md) | :heavy_check_mark: | N/A | | `status` | [BillingStatementStatus](../../models/components/BillingStatementStatus.md) | :heavy_check_mark: | The current status of the statement. | | `totals` | [BillingStatementTotals](../../models/components/BillingStatementTotals.md) | :heavy_check_mark: | Totals for the statement. | -| `groups` | List\<[Groups](../../models/components/Groups.md)> | :heavy_check_mark: | Array of statement groups. | \ No newline at end of file +| `groups` | List\<[BillingStatementGroups](../../models/components/BillingStatementGroups.md)> | :heavy_check_mark: | Array of statement groups. | \ No newline at end of file diff --git a/docs/models/components/BillingStatementGroups.md b/docs/models/components/BillingStatementGroups.md new file mode 100644 index 00000000..7afa3509 --- /dev/null +++ b/docs/models/components/BillingStatementGroups.md @@ -0,0 +1,12 @@ +# BillingStatementGroups + +A statement group. + + +## Fields + +| Field | Type | Required | Description | +| --------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------- | +| `object` | [BillingStatementGroupsObject](../../models/components/BillingStatementGroupsObject.md) | :heavy_check_mark: | String representing the object's type. Objects of the same type share the same value. | +| `timestamp` | *long* | :heavy_check_mark: | Unix timestamp (in milliseconds) of the date the group's payment attempts were created | +| `items` | List\<[BillingPaymentAttempt](../../models/components/BillingPaymentAttempt.md)> | :heavy_check_mark: | The payment attempts included in the group | \ No newline at end of file diff --git a/docs/models/components/Groups.md b/docs/models/components/Groups.md index 9621d07c..10202ee6 100644 --- a/docs/models/components/Groups.md +++ b/docs/models/components/Groups.md @@ -1,12 +1,9 @@ # Groups -A statement group. - ## Fields -| Field | Type | Required | Description | -| --------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------- | -| `object` | [BillingStatementGroupsObject](../../models/components/BillingStatementGroupsObject.md) | :heavy_check_mark: | String representing the object's type. Objects of the same type share the same value. | -| `timestamp` | *long* | :heavy_check_mark: | Unix timestamp (in milliseconds) of the date the group's payment attempts were created | -| `items` | List\<[BillingPaymentAttempt](../../models/components/BillingPaymentAttempt.md)> | :heavy_check_mark: | The payment attempts included in the group | \ No newline at end of file +| Field | Type | Required | Description | +| ------------------ | ------------------ | ------------------ | ------------------ | +| `id` | *String* | :heavy_check_mark: | N/A | +| `displayName` | *String* | :heavy_check_mark: | N/A | \ No newline at end of file diff --git a/docs/models/components/Level.md b/docs/models/components/Level.md new file mode 100644 index 00000000..d03e8d2e --- /dev/null +++ b/docs/models/components/Level.md @@ -0,0 +1,20 @@ +# Level + +The level used for the reverification + +## Example Usage + +```java +import com.clerk.backend_api.models.components.Level; + +Level value = Level.FIRST_FACTOR; +``` + + +## Values + +| Name | Value | +| --------------- | --------------- | +| `FIRST_FACTOR` | first_factor | +| `SECOND_FACTOR` | second_factor | +| `MULTI_FACTOR` | multi_factor | \ No newline at end of file diff --git a/docs/models/components/Reverification.md b/docs/models/components/Reverification.md new file mode 100644 index 00000000..27bd08fe --- /dev/null +++ b/docs/models/components/Reverification.md @@ -0,0 +1,20 @@ +# Reverification + +A reverification scoped to a session. Returned so a resource server can validate a reverification id received from its client. + + + +## Fields + +| Field | Type | Required | Description | +| -------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------- | +| `object` | [ReverificationObject](../../models/components/ReverificationObject.md) | :heavy_check_mark: | String representing the object's type. Objects of the same type share the same value.
| +| `id` | *String* | :heavy_check_mark: | N/A | +| `sessionId` | *String* | :heavy_check_mark: | N/A | +| `userId` | *String* | :heavy_check_mark: | N/A | +| `level` | [Level](../../models/components/Level.md) | :heavy_check_mark: | The level used for the reverification | +| `status` | [ReverificationStatus](../../models/components/ReverificationStatus.md) | :heavy_check_mark: | N/A | +| `firstFactorVerifiedAt` | *Optional\* | :heavy_check_mark: | Unix timestamp (ms) of the first factor verification, or null if not verified.
| +| `secondFactorVerifiedAt` | *Optional\* | :heavy_check_mark: | Unix timestamp (ms) of the second factor verification, or null if not verified.
| +| `createdAt` | *long* | :heavy_check_mark: | Unix timestamp of creation.
| +| `updatedAt` | *long* | :heavy_check_mark: | Unix timestamp of last update.
| \ No newline at end of file diff --git a/docs/models/components/ReverificationObject.md b/docs/models/components/ReverificationObject.md new file mode 100644 index 00000000..cf6b1afb --- /dev/null +++ b/docs/models/components/ReverificationObject.md @@ -0,0 +1,19 @@ +# ReverificationObject + +String representing the object's type. Objects of the same type share the same value. + + +## Example Usage + +```java +import com.clerk.backend_api.models.components.ReverificationObject; + +ReverificationObject value = ReverificationObject.REVERIFICATION; +``` + + +## Values + +| Name | Value | +| ---------------- | ---------------- | +| `REVERIFICATION` | reverification | \ No newline at end of file diff --git a/docs/models/components/ReverificationStatus.md b/docs/models/components/ReverificationStatus.md new file mode 100644 index 00000000..f58b0c12 --- /dev/null +++ b/docs/models/components/ReverificationStatus.md @@ -0,0 +1,18 @@ +# ReverificationStatus + +## Example Usage + +```java +import com.clerk.backend_api.models.components.ReverificationStatus; + +ReverificationStatus value = ReverificationStatus.NEEDS_FIRST_FACTOR; +``` + + +## Values + +| Name | Value | +| --------------------- | --------------------- | +| `NEEDS_FIRST_FACTOR` | needs_first_factor | +| `NEEDS_SECOND_FACTOR` | needs_second_factor | +| `COMPLETE` | complete | \ No newline at end of file diff --git a/docs/models/components/SCIMUserMetadata.md b/docs/models/components/SCIMUserMetadata.md new file mode 100644 index 00000000..e210e061 --- /dev/null +++ b/docs/models/components/SCIMUserMetadata.md @@ -0,0 +1,18 @@ +# SCIMUserMetadata + +Metadata describing a user's linkage to a directory. Included in user responses when directory data is requested, and in directory-triggered user webhooks. Its absence does not necessarily mean the user is not managed by a directory. + + + +## Fields + +| Field | Type | Required | Description | +| ------------------------------------------------------------------------------- | ------------------------------------------------------------------------------- | ------------------------------------------------------------------------------- | ------------------------------------------------------------------------------- | +| `id` | *String* | :heavy_check_mark: | The user's resource ID in this directory. | +| `directoryName` | *String* | :heavy_check_mark: | N/A | +| `provider` | *String* | :heavy_check_mark: | N/A | +| `enterpriseConnectionId` | *Optional\* | :heavy_check_mark: | N/A | +| `groups` | List\<[Groups](../../models/components/Groups.md)> | :heavy_minus_sign: | Omitted when groups were not loaded; an empty array means no group memberships. | +| `directoryId` | *String* | :heavy_check_mark: | The ID of the directory the user is provisioned from.
| +| `directoryEnabled` | *boolean* | :heavy_check_mark: | Whether the directory is currently enabled.
| +| `externalId` | *Optional\* | :heavy_check_mark: | The user's external ID as reported by the directory, if any.
| \ No newline at end of file diff --git a/docs/models/components/Scim.md b/docs/models/components/Scim.md index f23887a9..133bb38b 100644 --- a/docs/models/components/Scim.md +++ b/docs/models/components/Scim.md @@ -1,13 +1,19 @@ -# Scim +# ~~Scim~~ -Metadata describing a user's linkage to a directory. This object is only delivered on `user.created` and `user.updated` webhook events, and only when the user is provisioned through a directory. Its absence does not necessarily mean the user is not managed by a directory. +Alias of directory. Use directories for all links. +> :warning: **DEPRECATED**: This will be removed in a future release, please migrate away from it as soon as possible. ## Fields -| Field | Type | Required | Description | -| ---------------------------------------------------------------- | ---------------------------------------------------------------- | ---------------------------------------------------------------- | ---------------------------------------------------------------- | -| `directoryId` | *String* | :heavy_check_mark: | The ID of the directory the user is provisioned from.
| -| `directoryEnabled` | *Optional\* | :heavy_minus_sign: | Whether the directory is currently enabled. Omitted when false.
| -| `externalId` | *Optional\* | :heavy_check_mark: | The user's external ID as reported by the directory, if any.
| \ No newline at end of file +| Field | Type | Required | Description | +| ------------------------------------------------------------------------------- | ------------------------------------------------------------------------------- | ------------------------------------------------------------------------------- | ------------------------------------------------------------------------------- | +| `id` | *String* | :heavy_check_mark: | The user's resource ID in this directory. | +| `directoryName` | *String* | :heavy_check_mark: | N/A | +| `provider` | *String* | :heavy_check_mark: | N/A | +| `enterpriseConnectionId` | *Optional\* | :heavy_check_mark: | N/A | +| `groups` | List\<[UserScimGroups](../../models/components/UserScimGroups.md)> | :heavy_minus_sign: | Omitted when groups were not loaded; an empty array means no group memberships. | +| `directoryId` | *String* | :heavy_check_mark: | The ID of the directory the user is provisioned from.
| +| `directoryEnabled` | *boolean* | :heavy_check_mark: | Whether the directory is currently enabled.
| +| `externalId` | *Optional\* | :heavy_check_mark: | The user's external ID as reported by the directory, if any.
| \ No newline at end of file diff --git a/docs/models/components/User.md b/docs/models/components/User.md index 132abd4f..d0264863 100644 --- a/docs/models/components/User.md +++ b/docs/models/components/User.md @@ -52,4 +52,6 @@ Success | `lastActiveAt` | *Optional\* | :heavy_check_mark: | Unix timestamp of the latest session activity, with day precision.
| 1700690400000 | | `legalAcceptedAt` | *Optional\* | :heavy_check_mark: | Unix timestamp of when the user accepted the legal requirements.
| 1700690400000 | | `bypassClientTrust` | *Optional\* | :heavy_minus_sign: | When set to `true`, the user will bypass Device Trust checks during sign-in. | | -| `scim` | [JsonNullable\](../../models/components/Scim.md) | :heavy_minus_sign: | N/A | | \ No newline at end of file +| `directories` | List\<[SCIMUserMetadata](../../models/components/SCIMUserMetadata.md)> | :heavy_minus_sign: | All loaded directory links. Omitted when links were not loaded; an empty array means the user has no directory links.
| | +| ~~`directory`~~ | [Optional\](../../models/components/UserDirectory.md) | :heavy_minus_sign: | : warning: ** DEPRECATED **: This will be removed in a future release, please migrate away from it as soon as possible.

The most recently updated directory link. Use directories for all links. | | +| ~~`scim`~~ | [JsonNullable\](../../models/components/Scim.md) | :heavy_minus_sign: | : warning: ** DEPRECATED **: This will be removed in a future release, please migrate away from it as soon as possible.

Alias of directory. Use directories for all links. | | \ No newline at end of file diff --git a/docs/models/components/UserDirectory.md b/docs/models/components/UserDirectory.md new file mode 100644 index 00000000..00380151 --- /dev/null +++ b/docs/models/components/UserDirectory.md @@ -0,0 +1,19 @@ +# ~~UserDirectory~~ + +The most recently updated directory link. Use directories for all links. + +> :warning: **DEPRECATED**: This will be removed in a future release, please migrate away from it as soon as possible. + + +## Fields + +| Field | Type | Required | Description | +| ------------------------------------------------------------------------------- | ------------------------------------------------------------------------------- | ------------------------------------------------------------------------------- | ------------------------------------------------------------------------------- | +| `id` | *String* | :heavy_check_mark: | The user's resource ID in this directory. | +| `directoryName` | *String* | :heavy_check_mark: | N/A | +| `provider` | *String* | :heavy_check_mark: | N/A | +| `enterpriseConnectionId` | *Optional\* | :heavy_check_mark: | N/A | +| `groups` | List\<[UserGroups](../../models/components/UserGroups.md)> | :heavy_minus_sign: | Omitted when groups were not loaded; an empty array means no group memberships. | +| `directoryId` | *String* | :heavy_check_mark: | The ID of the directory the user is provisioned from.
| +| `directoryEnabled` | *boolean* | :heavy_check_mark: | Whether the directory is currently enabled.
| +| `externalId` | *Optional\* | :heavy_check_mark: | The user's external ID as reported by the directory, if any.
| \ No newline at end of file diff --git a/docs/models/components/UserGroups.md b/docs/models/components/UserGroups.md new file mode 100644 index 00000000..c27b02da --- /dev/null +++ b/docs/models/components/UserGroups.md @@ -0,0 +1,9 @@ +# UserGroups + + +## Fields + +| Field | Type | Required | Description | +| ------------------ | ------------------ | ------------------ | ------------------ | +| `id` | *String* | :heavy_check_mark: | N/A | +| `displayName` | *String* | :heavy_check_mark: | N/A | \ No newline at end of file diff --git a/docs/models/components/UserScimGroups.md b/docs/models/components/UserScimGroups.md new file mode 100644 index 00000000..781c9e94 --- /dev/null +++ b/docs/models/components/UserScimGroups.md @@ -0,0 +1,9 @@ +# UserScimGroups + + +## Fields + +| Field | Type | Required | Description | +| ------------------ | ------------------ | ------------------ | ------------------ | +| `id` | *String* | :heavy_check_mark: | N/A | +| `displayName` | *String* | :heavy_check_mark: | N/A | \ No newline at end of file diff --git a/docs/models/operations/AddDomainRequestBody.md b/docs/models/operations/AddDomainRequestBody.md index 0f688f57..c6a3fc0d 100644 --- a/docs/models/operations/AddDomainRequestBody.md +++ b/docs/models/operations/AddDomainRequestBody.md @@ -3,8 +3,8 @@ ## Fields -| Field | Type | Required | Description | -| ----------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------- | -| `name` | *String* | :heavy_check_mark: | The new domain name. Can contain the port for development instances. | -| `isSatellite` | *boolean* | :heavy_check_mark: | Marks the new domain as satellite. Only `true` is accepted at the moment. | -| `proxyUrl` | *JsonNullable\* | :heavy_minus_sign: | The full URL of the proxy which will forward requests to the Clerk Frontend API for this domain. Applicable only to production instances. | \ No newline at end of file +| Field | Type | Required | Description | +| ---------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------- | +| `name` | *String* | :heavy_check_mark: | The new domain name. Can contain the port for development instances. | +| `isSatellite` | *boolean* | :heavy_check_mark: | Marks the new domain as satellite. Set to `false` only when migrating a production instance from an active provider domain to a custom domain. | +| `proxyUrl` | *JsonNullable\* | :heavy_minus_sign: | The full URL of the proxy which will forward requests to the Clerk Frontend API for this domain. Applicable only to production instances. | \ No newline at end of file diff --git a/docs/models/operations/CreateOAuthApplicationRequestBody.md b/docs/models/operations/CreateOAuthApplicationRequestBody.md index b432dd40..25c7f8a5 100644 --- a/docs/models/operations/CreateOAuthApplicationRequestBody.md +++ b/docs/models/operations/CreateOAuthApplicationRequestBody.md @@ -3,13 +3,13 @@ ## Fields -| Field | Type | Required | Description | Example | -| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | -| `name` | *String* | :heavy_check_mark: | The name of the new OAuth application.
Max length: 256 | | -| `redirectUris` | List\<*String*> | :heavy_minus_sign: | An array of redirect URIs of the new OAuth application | | -| ~~`callbackUrl`~~ | *JsonNullable\* | :heavy_minus_sign: | : warning: ** DEPRECATED **: This will be removed in a future release, please migrate away from it as soon as possible.

The callback URL of the new OAuth application | | -| `scopes` | *JsonNullable\* | :heavy_minus_sign: | Define the application's built-in and custom scope ceiling. Provide scope keys as a space-delimited string. Custom keys must exist in the instance OAuth scope catalog. | profile email public_metadata | -| `consentScreenEnabled` | *JsonNullable\* | :heavy_minus_sign: | True to enable a consent screen to display in the authentication flow. | | -| `pkceRequired` | *JsonNullable\* | :heavy_minus_sign: | True to require the Proof Key of Code Exchange (PKCE) flow. | | -| `deviceAuthorizationGrantEnabled` | *JsonNullable\* | :heavy_minus_sign: | True to enable the OAuth Device Authorization Grant for this application. Enabling requires the OAuth Device Authorization Grant feature to be enabled for the instance. | | -| `public_` | *JsonNullable\* | :heavy_minus_sign: | If true, this client is public and you can use the Proof Key of Code Exchange (PKCE) flow. | | \ No newline at end of file +| Field | Type | Required | Description | Example | +| ----------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `name` | *String* | :heavy_check_mark: | The name of the new OAuth application.
Max length: 256 | | +| `redirectUris` | List\<*String*> | :heavy_minus_sign: | An array of redirect URIs of the new OAuth application | | +| ~~`callbackUrl`~~ | *JsonNullable\* | :heavy_minus_sign: | : warning: ** DEPRECATED **: This will be removed in a future release, please migrate away from it as soon as possible.

The callback URL of the new OAuth application | | +| `scopes` | *JsonNullable\* | :heavy_minus_sign: | Define the application's built-in and custom scope ceiling. Provide scope keys as a space-delimited string. Custom keys must exist in the instance OAuth scope catalog. | profile email public_metadata | +| `consentScreenEnabled` | *JsonNullable\* | :heavy_minus_sign: | True to enable a consent screen to display in the authentication flow. | | +| `pkceRequired` | *JsonNullable\* | :heavy_minus_sign: | True to require the Proof Key of Code Exchange (PKCE) flow. | | +| `deviceAuthorizationGrantEnabled` | *JsonNullable\* | :heavy_minus_sign: | True to enable the OAuth Device Authorization Grant for this application. Enabling requires the new OAuth IdP and a reachable device verification page. | | +| `public_` | *JsonNullable\* | :heavy_minus_sign: | If true, this client is public and you can use the Proof Key of Code Exchange (PKCE) flow. | | \ No newline at end of file diff --git a/docs/models/operations/DeleteDomainRequest.md b/docs/models/operations/DeleteDomainRequest.md index 3214099e..a7d4e1bd 100644 --- a/docs/models/operations/DeleteDomainRequest.md +++ b/docs/models/operations/DeleteDomainRequest.md @@ -3,6 +3,6 @@ ## Fields -| Field | Type | Required | Description | -| ---------------------------------------------------------------------- | ---------------------------------------------------------------------- | ---------------------------------------------------------------------- | ---------------------------------------------------------------------- | -| `domainId` | *String* | :heavy_check_mark: | The ID of the domain that will be deleted. Must be a satellite domain. | \ No newline at end of file +| Field | Type | Required | Description | +| ------------------------------------------ | ------------------------------------------ | ------------------------------------------ | ------------------------------------------ | +| `domainId` | *String* | :heavy_check_mark: | The ID of the domain that will be deleted. | \ No newline at end of file diff --git a/docs/models/operations/GetReverificationRequest.md b/docs/models/operations/GetReverificationRequest.md new file mode 100644 index 00000000..acb8874f --- /dev/null +++ b/docs/models/operations/GetReverificationRequest.md @@ -0,0 +1,9 @@ +# GetReverificationRequest + + +## Fields + +| Field | Type | Required | Description | +| --------------------------------------------------- | --------------------------------------------------- | --------------------------------------------------- | --------------------------------------------------- | +| `sessionId` | *String* | :heavy_check_mark: | The ID of the session the reverification belongs to | +| `reverificationId` | *String* | :heavy_check_mark: | The ID of the reverification | \ No newline at end of file diff --git a/docs/models/operations/GetReverificationResponse.md b/docs/models/operations/GetReverificationResponse.md new file mode 100644 index 00000000..6400f720 --- /dev/null +++ b/docs/models/operations/GetReverificationResponse.md @@ -0,0 +1,11 @@ +# GetReverificationResponse + + +## Fields + +| Field | Type | Required | Description | +| ------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------ | +| `contentType` | *String* | :heavy_check_mark: | HTTP response content type for this operation | +| `statusCode` | *int* | :heavy_check_mark: | HTTP response status code for this operation | +| `rawResponse` | [HttpResponse\](https://docs.oracle.com/en/java/javase/11/docs/api/java.net.http/java/net/http/HttpResponse.html) | :heavy_check_mark: | Raw HTTP response; suitable for custom response parsing | +| `reverification` | [Optional\](../../models/components/Reverification.md) | :heavy_minus_sign: | Success | \ No newline at end of file diff --git a/docs/models/operations/ResponseBody1.md b/docs/models/operations/ResponseBody1.md index 476bc0f1..06ab4d2a 100644 --- a/docs/models/operations/ResponseBody1.md +++ b/docs/models/operations/ResponseBody1.md @@ -10,6 +10,7 @@ | `clientId` | *String* | :heavy_check_mark: | N/A | client_2xhFjEI5X2qWRvtV13BzSj8H6Dk | | `subject` | *String* | :heavy_check_mark: | N/A | user_2xhFjEI5X2qWRvtV13BzSj8H6Dk | | `scopes` | List\<*String*> | :heavy_check_mark: | N/A | [
"read",
"write"
] | +| `aud` | List\<*String*> | :heavy_minus_sign: | The audiences of the access token. Omitted when no audience is set. | [
"https://api.example.com"
] | | `revoked` | *boolean* | :heavy_check_mark: | N/A | false | | `revocationReason` | *Optional\* | :heavy_check_mark: | N/A | Revoked by user | | `expired` | *boolean* | :heavy_check_mark: | N/A | false | diff --git a/docs/models/operations/UpdateOAuthApplicationRequestBody.md b/docs/models/operations/UpdateOAuthApplicationRequestBody.md index 5a63e9fc..209972f9 100644 --- a/docs/models/operations/UpdateOAuthApplicationRequestBody.md +++ b/docs/models/operations/UpdateOAuthApplicationRequestBody.md @@ -11,5 +11,5 @@ | `scopes` | *JsonNullable\* | :heavy_minus_sign: | Replace the application's complete built-in and custom scope ceiling. Provide scope keys as a space-delimited string. Custom keys must exist in the instance OAuth scope catalog. Required built-in scopes, such as `offline_access`, must be included in the replacement set, otherwise the request is rejected. Omit this field to leave all scope assignments unchanged. | profile email offline_access public_metadata private_metadata | | `consentScreenEnabled` | *JsonNullable\* | :heavy_minus_sign: | True to enable a consent screen to display in the authentication flow. This cannot be disabled for dynamically registered OAuth Applications. | | | `pkceRequired` | *JsonNullable\* | :heavy_minus_sign: | True to require the Proof Key of Code Exchange (PKCE) flow. | | -| `deviceAuthorizationGrantEnabled` | *JsonNullable\* | :heavy_minus_sign: | True to enable the OAuth Device Authorization Grant for this application. Enabling requires the OAuth Device Authorization Grant feature to be enabled for the instance. Omit this field to leave the setting unchanged. | | +| `deviceAuthorizationGrantEnabled` | *JsonNullable\* | :heavy_minus_sign: | True to enable the OAuth Device Authorization Grant for this application. Enabling requires the new OAuth IdP and a reachable device verification page. Omit this field to leave the setting unchanged. | | | `public_` | *JsonNullable\* | :heavy_minus_sign: | If true, this client is public and you can use the Proof Key of Code Exchange (PKCE) flow. | | \ No newline at end of file diff --git a/docs/sdks/domains/README.md b/docs/sdks/domains/README.md index afae3fa3..46a29053 100644 --- a/docs/sdks/domains/README.md +++ b/docs/sdks/domains/README.md @@ -6,7 +6,7 @@ * [list](#list) - List all instance domains * [add](#add) - Add a domain -* [delete](#delete) - Delete a satellite domain +* [delete](#delete) - Delete a domain * [update](#update) - Update a domain ## list @@ -57,7 +57,10 @@ public class Application { Add a new domain for your instance. Useful in the case of multi-domain instances, allows adding satellite domains to an instance. The new domain must have a `name`. The domain name can contain the port for development instances, like `localhost:3000`. -At the moment, instances can have only one primary domain, so the `is_satellite` parameter must be set to `true`. +Set `is_satellite` to `true` to add a satellite domain. +To migrate a production instance from an active provider domain to its first custom primary domain, +set `is_satellite` to `false`. The custom domain becomes active and the provider domain stays attached. +Additional custom primary domains are not supported. If you're planning to configure the new satellite domain to run behind a proxy, pass the `proxy_url` parameter accordingly. ### Example Usage @@ -108,8 +111,8 @@ public class Application { ## delete -Deletes a satellite domain for the instance. -It is currently not possible to delete the instance's primary domain. +Deletes a domain for the instance. +The instance's active domain cannot be deleted. ### Example Usage @@ -143,9 +146,9 @@ public class Application { ### Parameters -| Parameter | Type | Required | Description | -| ---------------------------------------------------------------------- | ---------------------------------------------------------------------- | ---------------------------------------------------------------------- | ---------------------------------------------------------------------- | -| `domainId` | *String* | :heavy_check_mark: | The ID of the domain that will be deleted. Must be a satellite domain. | +| Parameter | Type | Required | Description | +| ------------------------------------------ | ------------------------------------------ | ------------------------------------------ | ------------------------------------------ | +| `domainId` | *String* | :heavy_check_mark: | The ID of the domain that will be deleted. | ### Response diff --git a/docs/sdks/phonenumbers/README.md b/docs/sdks/phonenumbers/README.md index 69e0254f..2672a283 100644 --- a/docs/sdks/phonenumbers/README.md +++ b/docs/sdks/phonenumbers/README.md @@ -279,7 +279,15 @@ verification_id, and returns the verification with its updated status backend driving its own frontend can react on every attempt — an incorrect or expired code is reported through the status, not as an error. Resubmitting a verification whose code was already accepted is rejected with a -`verification_already_verified` error. If the code +`verification_already_verified` error. If the code for this verification +could not be sent (the SMS provider refused or failed the send after +prepare_verification had returned), the attempt is rejected with a +`verification_code_not_sent` error and no attempt is counted; call +prepare_verification again to send a new code. If too many codes have been +checked for this phone number recently, the attempt is rejected with a +`verification_code_too_many_attempts` error and no attempt is counted; the +limit is per phone number, so wait for the `Retry-After` period rather than +sending a new code. If the code is correct and the phone number is not already verified, it is also marked as verified as a side effect (just as it would be in a frontend verification flow); an already verified phone number is left unchanged. It never creates @@ -333,11 +341,11 @@ public class Application { ### Errors -| Error Type | Status Code | Content Type | -| ------------------------- | ------------------------- | ------------------------- | -| models/errors/ClerkErrors | 400, 401, 403, 404 | application/json | -| models/errors/ClerkErrors | 500 | application/json | -| models/errors/SDKError | 4XX, 5XX | \*/\* | +| Error Type | Status Code | Content Type | +| ---------------------------- | ---------------------------- | ---------------------------- | +| models/errors/ClerkErrors | 400, 401, 403, 404, 422, 429 | application/json | +| models/errors/ClerkErrors | 500 | application/json | +| models/errors/SDKError | 4XX, 5XX | \*/\* | ## replaceForUser diff --git a/docs/sdks/sessions/README.md b/docs/sdks/sessions/README.md index 5af8f59f..3e15dff6 100644 --- a/docs/sdks/sessions/README.md +++ b/docs/sdks/sessions/README.md @@ -8,6 +8,7 @@ * [create](#create) - Create a new active session * [get](#get) - Retrieve a session * [refresh](#refresh) - Refresh a session +* [getReverification](#getreverification) - Retrieve a reverification * [revoke](#revoke) - Revoke a session * [createToken](#createtoken) - Create a session token * [createTokenFromTemplate](#createtokenfromtemplate) - Create a session token from a JWT template @@ -242,6 +243,60 @@ public class Application { | models/errors/ClerkErrors | 400, 401 | application/json | | models/errors/SDKError | 4XX, 5XX | \*/\* | +## getReverification + +Retrieve a reverification scoped to a session. A resource server can use this to validate a reverification id it received from its client: confirm it is real, scoped to the expected session, completed, and how fresh each factor is. Single-use / replay detection is the caller's responsibility (the id is stable, so the caller dedups consumed ids). + + +### Example Usage + + +```java +package hello.world; + +import com.clerk.backend_api.Clerk; +import com.clerk.backend_api.models.errors.ClerkErrors; +import com.clerk.backend_api.models.operations.GetReverificationResponse; +import java.lang.Exception; + +public class Application { + + public static void main(String[] args) throws ClerkErrors, Exception { + + Clerk sdk = Clerk.builder() + .bearerAuth(System.getenv().getOrDefault("BEARER_AUTH", "")) + .build(); + + GetReverificationResponse res = sdk.sessions().getReverification() + .sessionId("") + .reverificationId("") + .call(); + + if (res.reverification().isPresent()) { + System.out.println(res.reverification().get()); + } + } +} +``` + +### Parameters + +| Parameter | Type | Required | Description | +| --------------------------------------------------- | --------------------------------------------------- | --------------------------------------------------- | --------------------------------------------------- | +| `sessionId` | *String* | :heavy_check_mark: | The ID of the session the reverification belongs to | +| `reverificationId` | *String* | :heavy_check_mark: | The ID of the reverification | + +### Response + +**[GetReverificationResponse](../../models/operations/GetReverificationResponse.md)** + +### Errors + +| Error Type | Status Code | Content Type | +| ------------------------- | ------------------------- | ------------------------- | +| models/errors/ClerkErrors | 400, 401, 404 | application/json | +| models/errors/SDKError | 4XX, 5XX | \*/\* | + ## revoke Sets the status of a session as "revoked", which is an unauthenticated state. diff --git a/docs/sdks/users/README.md b/docs/sdks/users/README.md index 1f4b7d79..1898d70a 100644 --- a/docs/sdks/users/README.md +++ b/docs/sdks/users/README.md @@ -1553,7 +1553,7 @@ public class Application { ## deletePasskey -Delete the passkey identification for a given user and notify them through email. +Delete the passkey identification for a given user. The user is notified through email or SMS unless the passkey registration was never completed. ### Example Usage diff --git a/gradle.properties b/gradle.properties index 6bc1b685..905a0fff 100644 --- a/gradle.properties +++ b/gradle.properties @@ -1,4 +1,4 @@ groupId=com.clerk artifactId=backend-api -version=6.1.0 +version=6.1.1 org.gradle.jvmargs=-Xmx4g -XX:MaxMetaspaceSize=1g diff --git a/src/main/java/com/clerk/backend_api/Domains.java b/src/main/java/com/clerk/backend_api/Domains.java index 88147167..7c67bb16 100644 --- a/src/main/java/com/clerk/backend_api/Domains.java +++ b/src/main/java/com/clerk/backend_api/Domains.java @@ -90,8 +90,11 @@ public ListDomainsResponse list(Optional options) { * Useful in the case of multi-domain instances, allows adding satellite domains to an instance. * The new domain must have a `name`. The domain name can contain the port for development instances, * like `localhost:3000`. - * At the moment, instances can have only one primary domain, so the `is_satellite` parameter must be - * set to `true`. + * Set `is_satellite` to `true` to add a satellite domain. + * To migrate a production instance from an active provider domain to its first custom primary domain, + * set `is_satellite` to `false`. The custom domain becomes active and the provider domain stays + * attached. + * Additional custom primary domains are not supported. * If you're planning to configure the new satellite domain to run behind a proxy, pass the `proxy_url` * parameter accordingly. * @@ -108,8 +111,11 @@ public AddDomainRequestBuilder add() { * Useful in the case of multi-domain instances, allows adding satellite domains to an instance. * The new domain must have a `name`. The domain name can contain the port for development instances, * like `localhost:3000`. - * At the moment, instances can have only one primary domain, so the `is_satellite` parameter must be - * set to `true`. + * Set `is_satellite` to `true` to add a satellite domain. + * To migrate a production instance from an active provider domain to its first custom primary domain, + * set `is_satellite` to `false`. The custom domain becomes active and the provider domain stays + * attached. + * Additional custom primary domains are not supported. * If you're planning to configure the new satellite domain to run behind a proxy, pass the `proxy_url` * parameter accordingly. * @@ -127,8 +133,11 @@ public AddDomainResponse addDirect() { * Useful in the case of multi-domain instances, allows adding satellite domains to an instance. * The new domain must have a `name`. The domain name can contain the port for development instances, * like `localhost:3000`. - * At the moment, instances can have only one primary domain, so the `is_satellite` parameter must be - * set to `true`. + * Set `is_satellite` to `true` to add a satellite domain. + * To migrate a production instance from an active provider domain to its first custom primary domain, + * set `is_satellite` to `false`. The custom domain becomes active and the provider domain stays + * attached. + * Additional custom primary domains are not supported. * If you're planning to configure the new satellite domain to run behind a proxy, pass the `proxy_url` * parameter accordingly. * @@ -144,10 +153,10 @@ public AddDomainResponse add(Optional request, O } /** - * Delete a satellite domain + * Delete a domain * - *

Deletes a satellite domain for the instance. - * It is currently not possible to delete the instance's primary domain. + *

Deletes a domain for the instance. + * The instance's active domain cannot be deleted. * * @return The call builder */ @@ -156,12 +165,12 @@ public DeleteDomainRequestBuilder delete() { } /** - * Delete a satellite domain + * Delete a domain * - *

Deletes a satellite domain for the instance. - * It is currently not possible to delete the instance's primary domain. + *

Deletes a domain for the instance. + * The instance's active domain cannot be deleted. * - * @param domainId The ID of the domain that will be deleted. Must be a satellite domain. + * @param domainId The ID of the domain that will be deleted. * @return The response from the API call * @throws RuntimeException subclass if the API call fails */ @@ -170,12 +179,12 @@ public DeleteDomainResponse delete(String domainId) { } /** - * Delete a satellite domain + * Delete a domain * - *

Deletes a satellite domain for the instance. - * It is currently not possible to delete the instance's primary domain. + *

Deletes a domain for the instance. + * The instance's active domain cannot be deleted. * - * @param domainId The ID of the domain that will be deleted. Must be a satellite domain. + * @param domainId The ID of the domain that will be deleted. * @param options additional options * @return The response from the API call * @throws RuntimeException subclass if the API call fails diff --git a/src/main/java/com/clerk/backend_api/PhoneNumbers.java b/src/main/java/com/clerk/backend_api/PhoneNumbers.java index 3af70936..8aac9dd4 100644 --- a/src/main/java/com/clerk/backend_api/PhoneNumbers.java +++ b/src/main/java/com/clerk/backend_api/PhoneNumbers.java @@ -291,7 +291,15 @@ public PreparePhoneNumberVerificationResponse prepareVerification(String phoneNu * backend driving its own frontend can react on every attempt — an incorrect * or expired code is reported through the status, not as an error. Resubmitting * a verification whose code was already accepted is rejected with a - * `verification_already_verified` error. If the code + * `verification_already_verified` error. If the code for this verification + * could not be sent (the SMS provider refused or failed the send after + * prepare_verification had returned), the attempt is rejected with a + * `verification_code_not_sent` error and no attempt is counted; call + * prepare_verification again to send a new code. If too many codes have been + * checked for this phone number recently, the attempt is rejected with a + * `verification_code_too_many_attempts` error and no attempt is counted; the + * limit is per phone number, so wait for the `Retry-After` period rather than + * sending a new code. If the code * is correct and the phone number is not already verified, it is also marked * as verified as a side effect (just as it would be in a frontend verification * flow); an already verified phone number is left unchanged. It never creates @@ -312,7 +320,15 @@ public AttemptPhoneNumberVerificationRequestBuilder attemptVerification() { * backend driving its own frontend can react on every attempt — an incorrect * or expired code is reported through the status, not as an error. Resubmitting * a verification whose code was already accepted is rejected with a - * `verification_already_verified` error. If the code + * `verification_already_verified` error. If the code for this verification + * could not be sent (the SMS provider refused or failed the send after + * prepare_verification had returned), the attempt is rejected with a + * `verification_code_not_sent` error and no attempt is counted; call + * prepare_verification again to send a new code. If too many codes have been + * checked for this phone number recently, the attempt is rejected with a + * `verification_code_too_many_attempts` error and no attempt is counted; the + * limit is per phone number, so wait for the `Retry-After` period rather than + * sending a new code. If the code * is correct and the phone number is not already verified, it is also marked * as verified as a side effect (just as it would be in a frontend verification * flow); an already verified phone number is left unchanged. It never creates @@ -336,7 +352,15 @@ public AttemptPhoneNumberVerificationResponse attemptVerification(String phoneNu * backend driving its own frontend can react on every attempt — an incorrect * or expired code is reported through the status, not as an error. Resubmitting * a verification whose code was already accepted is rejected with a - * `verification_already_verified` error. If the code + * `verification_already_verified` error. If the code for this verification + * could not be sent (the SMS provider refused or failed the send after + * prepare_verification had returned), the attempt is rejected with a + * `verification_code_not_sent` error and no attempt is counted; call + * prepare_verification again to send a new code. If too many codes have been + * checked for this phone number recently, the attempt is rejected with a + * `verification_code_too_many_attempts` error and no attempt is counted; the + * limit is per phone number, so wait for the `Retry-After` period rather than + * sending a new code. If the code * is correct and the phone number is not already verified, it is also marked * as verified as a side effect (just as it would be in a frontend verification * flow); an already verified phone number is left unchanged. It never creates diff --git a/src/main/java/com/clerk/backend_api/SDKConfiguration.java b/src/main/java/com/clerk/backend_api/SDKConfiguration.java index 963220be..ddcdbb46 100644 --- a/src/main/java/com/clerk/backend_api/SDKConfiguration.java +++ b/src/main/java/com/clerk/backend_api/SDKConfiguration.java @@ -16,8 +16,8 @@ public class SDKConfiguration { private static final String LANGUAGE = "java"; public static final String OPENAPI_DOC_VERSION = "2026-05-12"; - public static final String SDK_VERSION = "6.1.0"; - public static final String GEN_VERSION = "2.937.18"; + public static final String SDK_VERSION = "6.1.1"; + public static final String GEN_VERSION = "2.938.0"; private static final String BASE_PACKAGE = "com.clerk.backend_api"; public static final String USER_AGENT = String.format("speakeasy-sdk/%s %s %s %s %s", diff --git a/src/main/java/com/clerk/backend_api/Sessions.java b/src/main/java/com/clerk/backend_api/Sessions.java index 3dae2e4f..17a4cce6 100644 --- a/src/main/java/com/clerk/backend_api/Sessions.java +++ b/src/main/java/com/clerk/backend_api/Sessions.java @@ -16,6 +16,9 @@ import com.clerk.backend_api.models.operations.CreateSessionTokenRequestBody; import com.clerk.backend_api.models.operations.CreateSessionTokenRequestBuilder; import com.clerk.backend_api.models.operations.CreateSessionTokenResponse; +import com.clerk.backend_api.models.operations.GetReverificationRequest; +import com.clerk.backend_api.models.operations.GetReverificationRequestBuilder; +import com.clerk.backend_api.models.operations.GetReverificationResponse; import com.clerk.backend_api.models.operations.GetSessionListRequest; import com.clerk.backend_api.models.operations.GetSessionListRequestBuilder; import com.clerk.backend_api.models.operations.GetSessionListResponse; @@ -32,6 +35,7 @@ import com.clerk.backend_api.operations.CreateSession; import com.clerk.backend_api.operations.CreateSessionToken; import com.clerk.backend_api.operations.CreateSessionTokenFromTemplate; +import com.clerk.backend_api.operations.GetReverification; import com.clerk.backend_api.operations.GetSession; import com.clerk.backend_api.operations.GetSessionList; import com.clerk.backend_api.operations.RefreshSession; @@ -265,6 +269,65 @@ public RefreshSessionResponse refresh( return operation.handleResponse(operation.doRequest(request)); } + /** + * Retrieve a reverification + * + *

Retrieve a reverification scoped to a session. A resource server can use this to validate a + * reverification id it received from its client: confirm it is real, scoped to the expected session, + * completed, and how fresh each factor is. Single-use / replay detection is the caller's + * responsibility (the id is stable, so the caller dedups consumed ids). + * + * @return The call builder + */ + public GetReverificationRequestBuilder getReverification() { + return new GetReverificationRequestBuilder(sdkConfiguration); + } + + /** + * Retrieve a reverification + * + *

Retrieve a reverification scoped to a session. A resource server can use this to validate a + * reverification id it received from its client: confirm it is real, scoped to the expected session, + * completed, and how fresh each factor is. Single-use / replay detection is the caller's + * responsibility (the id is stable, so the caller dedups consumed ids). + * + * @param sessionId The ID of the session the reverification belongs to + * @param reverificationId The ID of the reverification + * @return The response from the API call + * @throws RuntimeException subclass if the API call fails + */ + public GetReverificationResponse getReverification(String sessionId, String reverificationId) { + return getReverification(sessionId, reverificationId, Optional.empty()); + } + + /** + * Retrieve a reverification + * + *

Retrieve a reverification scoped to a session. A resource server can use this to validate a + * reverification id it received from its client: confirm it is real, scoped to the expected session, + * completed, and how fresh each factor is. Single-use / replay detection is the caller's + * responsibility (the id is stable, so the caller dedups consumed ids). + * + * @param sessionId The ID of the session the reverification belongs to + * @param reverificationId The ID of the reverification + * @param options additional options + * @return The response from the API call + * @throws RuntimeException subclass if the API call fails + */ + public GetReverificationResponse getReverification( + String sessionId, String reverificationId, + Optional options) { + GetReverificationRequest request = + GetReverificationRequest + .builder() + .sessionId(sessionId) + .reverificationId(reverificationId) + .build(); + RequestOperation operation + = new GetReverification.Sync(sdkConfiguration, options, _headers); + return operation.handleResponse(operation.doRequest(request)); + } + /** * Revoke a session * diff --git a/src/main/java/com/clerk/backend_api/Users.java b/src/main/java/com/clerk/backend_api/Users.java index c0fe9642..3784fe5e 100644 --- a/src/main/java/com/clerk/backend_api/Users.java +++ b/src/main/java/com/clerk/backend_api/Users.java @@ -1633,7 +1633,8 @@ public DeleteBackupCodeResponse deleteBackupCodes(String userId, Optional

Delete the passkey identification for a given user. The user is notified through email or SMS unless + * the passkey registration was never completed. * * @return The call builder */ @@ -1644,7 +1645,8 @@ public UserPasskeyDeleteRequestBuilder deletePasskey() { /** * Delete a user passkey * - *

Delete the passkey identification for a given user and notify them through email. + *

Delete the passkey identification for a given user. The user is notified through email or SMS unless + * the passkey registration was never completed. * * @param userId The ID of the user that owns the passkey identity * @param passkeyIdentificationId The ID of the passkey identity to be deleted @@ -1658,7 +1660,8 @@ public UserPasskeyDeleteResponse deletePasskey(String userId, String passkeyIden /** * Delete a user passkey * - *

Delete the passkey identification for a given user and notify them through email. + *

Delete the passkey identification for a given user. The user is notified through email or SMS unless + * the passkey registration was never completed. * * @param userId The ID of the user that owns the passkey identity * @param passkeyIdentificationId The ID of the passkey identity to be deleted diff --git a/src/main/java/com/clerk/backend_api/models/components/BillingStatement.java b/src/main/java/com/clerk/backend_api/models/components/BillingStatement.java index 68fe8ec3..3ab1a618 100644 --- a/src/main/java/com/clerk/backend_api/models/components/BillingStatement.java +++ b/src/main/java/com/clerk/backend_api/models/components/BillingStatement.java @@ -58,7 +58,7 @@ public class BillingStatement { * Array of statement groups. */ @JsonProperty("groups") - private List groups; + private List groups; @JsonCreator public BillingStatement( @@ -69,7 +69,7 @@ public BillingStatement( @JsonProperty("payer") CommercePayerResponse payer, @JsonProperty("status") BillingStatementStatus status, @JsonProperty("totals") BillingStatementTotals totals, - @JsonProperty("groups") List groups) { + @JsonProperty("groups") List groups) { Utils.checkNotNull(object, "object"); Utils.checkNotNull(id, "id"); Utils.checkNotNull(instanceId, "instanceId"); @@ -145,7 +145,7 @@ public BillingStatementTotals totals() { * Array of statement groups. */ @JsonIgnore - public List groups() { + public List groups() { return groups; } @@ -217,7 +217,7 @@ public BillingStatement withTotals(BillingStatementTotals totals) { /** * Array of statement groups. */ - public BillingStatement withGroups(List groups) { + public BillingStatement withGroups(List groups) { Utils.checkNotNull(groups, "groups"); this.groups = groups; return this; @@ -281,7 +281,7 @@ public final static class Builder { private BillingStatementTotals totals; - private List groups; + private List groups; private Builder() { // force use of static builder() method @@ -358,7 +358,7 @@ public Builder totals(BillingStatementTotals totals) { /** * Array of statement groups. */ - public Builder groups(List groups) { + public Builder groups(List groups) { Utils.checkNotNull(groups, "groups"); this.groups = groups; return this; diff --git a/src/main/java/com/clerk/backend_api/models/components/BillingStatementGroups.java b/src/main/java/com/clerk/backend_api/models/components/BillingStatementGroups.java new file mode 100644 index 00000000..e90b4d50 --- /dev/null +++ b/src/main/java/com/clerk/backend_api/models/components/BillingStatementGroups.java @@ -0,0 +1,187 @@ +/* + * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + */ +package com.clerk.backend_api.models.components; + +import com.clerk.backend_api.utils.Utils; +import com.fasterxml.jackson.annotation.JsonCreator; +import com.fasterxml.jackson.annotation.JsonIgnore; +import com.fasterxml.jackson.annotation.JsonProperty; +import java.lang.Long; +import java.lang.Override; +import java.lang.String; +import java.util.List; + +/** + * BillingStatementGroups + * + *

A statement group. + */ +public class BillingStatementGroups { + /** + * String representing the object's type. Objects of the same type share the same value. + */ + @JsonProperty("object") + private BillingStatementGroupsObject object; + + /** + * Unix timestamp (in milliseconds) of the date the group's payment attempts were created + */ + @JsonProperty("timestamp") + private long timestamp; + + /** + * The payment attempts included in the group + */ + @JsonProperty("items") + private List items; + + @JsonCreator + public BillingStatementGroups( + @JsonProperty("object") BillingStatementGroupsObject object, + @JsonProperty("timestamp") long timestamp, + @JsonProperty("items") List items) { + Utils.checkNotNull(object, "object"); + Utils.checkNotNull(timestamp, "timestamp"); + Utils.checkNotNull(items, "items"); + this.object = object; + this.timestamp = timestamp; + this.items = items; + } + + /** + * String representing the object's type. Objects of the same type share the same value. + */ + @JsonIgnore + public BillingStatementGroupsObject object() { + return object; + } + + /** + * Unix timestamp (in milliseconds) of the date the group's payment attempts were created + */ + @JsonIgnore + public long timestamp() { + return timestamp; + } + + /** + * The payment attempts included in the group + */ + @JsonIgnore + public List items() { + return items; + } + + public static Builder builder() { + return new Builder(); + } + + + /** + * String representing the object's type. Objects of the same type share the same value. + */ + public BillingStatementGroups withObject(BillingStatementGroupsObject object) { + Utils.checkNotNull(object, "object"); + this.object = object; + return this; + } + + /** + * Unix timestamp (in milliseconds) of the date the group's payment attempts were created + */ + public BillingStatementGroups withTimestamp(long timestamp) { + Utils.checkNotNull(timestamp, "timestamp"); + this.timestamp = timestamp; + return this; + } + + /** + * The payment attempts included in the group + */ + public BillingStatementGroups withItems(List items) { + Utils.checkNotNull(items, "items"); + this.items = items; + return this; + } + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + BillingStatementGroups other = (BillingStatementGroups) o; + return + Utils.enhancedDeepEquals(this.object, other.object) && + Utils.enhancedDeepEquals(this.timestamp, other.timestamp) && + Utils.enhancedDeepEquals(this.items, other.items); + } + + @Override + public int hashCode() { + return Utils.enhancedHash( + object, timestamp, items); + } + + @Override + public String toString() { + return Utils.toString(BillingStatementGroups.class, + "object", object, + "timestamp", timestamp, + "items", items); + } + + @SuppressWarnings("UnusedReturnValue") + public final static class Builder { + + private BillingStatementGroupsObject object; + + private Long timestamp; + + private List items; + + private Builder() { + // force use of static builder() method + } + + + /** + * String representing the object's type. Objects of the same type share the same value. + */ + public Builder object(BillingStatementGroupsObject object) { + Utils.checkNotNull(object, "object"); + this.object = object; + return this; + } + + + /** + * Unix timestamp (in milliseconds) of the date the group's payment attempts were created + */ + public Builder timestamp(long timestamp) { + Utils.checkNotNull(timestamp, "timestamp"); + this.timestamp = timestamp; + return this; + } + + + /** + * The payment attempts included in the group + */ + public Builder items(List items) { + Utils.checkNotNull(items, "items"); + this.items = items; + return this; + } + + public BillingStatementGroups build() { + + return new BillingStatementGroups( + object, timestamp, items); + } + + } +} diff --git a/src/main/java/com/clerk/backend_api/models/components/Groups.java b/src/main/java/com/clerk/backend_api/models/components/Groups.java index 34afa362..325aa437 100644 --- a/src/main/java/com/clerk/backend_api/models/components/Groups.java +++ b/src/main/java/com/clerk/backend_api/models/components/Groups.java @@ -7,70 +7,37 @@ import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; -import java.lang.Long; import java.lang.Override; import java.lang.String; -import java.util.List; -/** - * Groups - * - *

A statement group. - */ + public class Groups { - /** - * String representing the object's type. Objects of the same type share the same value. - */ - @JsonProperty("object") - private BillingStatementGroupsObject object; - - /** - * Unix timestamp (in milliseconds) of the date the group's payment attempts were created - */ - @JsonProperty("timestamp") - private long timestamp; - - /** - * The payment attempts included in the group - */ - @JsonProperty("items") - private List items; + + @JsonProperty("id") + private String id; + + + @JsonProperty("display_name") + private String displayName; @JsonCreator public Groups( - @JsonProperty("object") BillingStatementGroupsObject object, - @JsonProperty("timestamp") long timestamp, - @JsonProperty("items") List items) { - Utils.checkNotNull(object, "object"); - Utils.checkNotNull(timestamp, "timestamp"); - Utils.checkNotNull(items, "items"); - this.object = object; - this.timestamp = timestamp; - this.items = items; - } - - /** - * String representing the object's type. Objects of the same type share the same value. - */ - @JsonIgnore - public BillingStatementGroupsObject object() { - return object; + @JsonProperty("id") String id, + @JsonProperty("display_name") String displayName) { + Utils.checkNotNull(id, "id"); + Utils.checkNotNull(displayName, "displayName"); + this.id = id; + this.displayName = displayName; } - /** - * Unix timestamp (in milliseconds) of the date the group's payment attempts were created - */ @JsonIgnore - public long timestamp() { - return timestamp; + public String id() { + return id; } - /** - * The payment attempts included in the group - */ @JsonIgnore - public List items() { - return items; + public String displayName() { + return displayName; } public static Builder builder() { @@ -78,30 +45,15 @@ public static Builder builder() { } - /** - * String representing the object's type. Objects of the same type share the same value. - */ - public Groups withObject(BillingStatementGroupsObject object) { - Utils.checkNotNull(object, "object"); - this.object = object; + public Groups withId(String id) { + Utils.checkNotNull(id, "id"); + this.id = id; return this; } - /** - * Unix timestamp (in milliseconds) of the date the group's payment attempts were created - */ - public Groups withTimestamp(long timestamp) { - Utils.checkNotNull(timestamp, "timestamp"); - this.timestamp = timestamp; - return this; - } - - /** - * The payment attempts included in the group - */ - public Groups withItems(List items) { - Utils.checkNotNull(items, "items"); - this.items = items; + public Groups withDisplayName(String displayName) { + Utils.checkNotNull(displayName, "displayName"); + this.displayName = displayName; return this; } @@ -115,72 +67,52 @@ public boolean equals(java.lang.Object o) { } Groups other = (Groups) o; return - Utils.enhancedDeepEquals(this.object, other.object) && - Utils.enhancedDeepEquals(this.timestamp, other.timestamp) && - Utils.enhancedDeepEquals(this.items, other.items); + Utils.enhancedDeepEquals(this.id, other.id) && + Utils.enhancedDeepEquals(this.displayName, other.displayName); } @Override public int hashCode() { return Utils.enhancedHash( - object, timestamp, items); + id, displayName); } @Override public String toString() { return Utils.toString(Groups.class, - "object", object, - "timestamp", timestamp, - "items", items); + "id", id, + "displayName", displayName); } @SuppressWarnings("UnusedReturnValue") public final static class Builder { - private BillingStatementGroupsObject object; - - private Long timestamp; + private String id; - private List items; + private String displayName; private Builder() { // force use of static builder() method } - /** - * String representing the object's type. Objects of the same type share the same value. - */ - public Builder object(BillingStatementGroupsObject object) { - Utils.checkNotNull(object, "object"); - this.object = object; - return this; - } - - - /** - * Unix timestamp (in milliseconds) of the date the group's payment attempts were created - */ - public Builder timestamp(long timestamp) { - Utils.checkNotNull(timestamp, "timestamp"); - this.timestamp = timestamp; + public Builder id(String id) { + Utils.checkNotNull(id, "id"); + this.id = id; return this; } - /** - * The payment attempts included in the group - */ - public Builder items(List items) { - Utils.checkNotNull(items, "items"); - this.items = items; + public Builder displayName(String displayName) { + Utils.checkNotNull(displayName, "displayName"); + this.displayName = displayName; return this; } public Groups build() { return new Groups( - object, timestamp, items); + id, displayName); } } diff --git a/src/main/java/com/clerk/backend_api/models/components/Level.java b/src/main/java/com/clerk/backend_api/models/components/Level.java new file mode 100644 index 00000000..fd72c210 --- /dev/null +++ b/src/main/java/com/clerk/backend_api/models/components/Level.java @@ -0,0 +1,41 @@ +/* + * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + */ +package com.clerk.backend_api.models.components; + +import com.fasterxml.jackson.annotation.JsonValue; +import java.lang.String; +import java.util.Objects; +import java.util.Optional; + +/** + * Level + * + *

The level used for the reverification + */ +public enum Level { + FIRST_FACTOR("first_factor"), + SECOND_FACTOR("second_factor"), + MULTI_FACTOR("multi_factor"); + + @JsonValue + private final String value; + + Level(String value) { + this.value = value; + } + + public String value() { + return value; + } + + public static Optional fromValue(String value) { + for (Level o: Level.values()) { + if (Objects.deepEquals(o.value, value)) { + return Optional.of(o); + } + } + return Optional.empty(); + } +} + diff --git a/src/main/java/com/clerk/backend_api/models/components/Reverification.java b/src/main/java/com/clerk/backend_api/models/components/Reverification.java new file mode 100644 index 00000000..2c6053e4 --- /dev/null +++ b/src/main/java/com/clerk/backend_api/models/components/Reverification.java @@ -0,0 +1,487 @@ +/* + * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + */ +package com.clerk.backend_api.models.components; + +import com.clerk.backend_api.utils.Utils; +import com.fasterxml.jackson.annotation.JsonCreator; +import com.fasterxml.jackson.annotation.JsonIgnore; +import com.fasterxml.jackson.annotation.JsonInclude.Include; +import com.fasterxml.jackson.annotation.JsonInclude; +import com.fasterxml.jackson.annotation.JsonProperty; +import java.lang.Long; +import java.lang.Override; +import java.lang.String; +import java.util.Optional; + +/** + * Reverification + * + *

A reverification scoped to a session. Returned so a resource server can validate a reverification id + * received from its client. + */ +public class Reverification { + /** + * String representing the object's type. Objects of the same type share the same value. + */ + @JsonProperty("object") + private ReverificationObject object; + + + @JsonProperty("id") + private String id; + + + @JsonProperty("session_id") + private String sessionId; + + + @JsonProperty("user_id") + private String userId; + + /** + * The level used for the reverification + */ + @JsonProperty("level") + private Level level; + + + @JsonProperty("status") + private ReverificationStatus status; + + /** + * Unix timestamp (ms) of the first factor verification, or null if not verified. + */ + @JsonInclude(Include.ALWAYS) + @JsonProperty("first_factor_verified_at") + private Optional firstFactorVerifiedAt; + + /** + * Unix timestamp (ms) of the second factor verification, or null if not verified. + */ + @JsonInclude(Include.ALWAYS) + @JsonProperty("second_factor_verified_at") + private Optional secondFactorVerifiedAt; + + /** + * Unix timestamp of creation. + */ + @JsonProperty("created_at") + private long createdAt; + + /** + * Unix timestamp of last update. + */ + @JsonProperty("updated_at") + private long updatedAt; + + @JsonCreator + public Reverification( + @JsonProperty("object") ReverificationObject object, + @JsonProperty("id") String id, + @JsonProperty("session_id") String sessionId, + @JsonProperty("user_id") String userId, + @JsonProperty("level") Level level, + @JsonProperty("status") ReverificationStatus status, + @JsonProperty("first_factor_verified_at") Optional firstFactorVerifiedAt, + @JsonProperty("second_factor_verified_at") Optional secondFactorVerifiedAt, + @JsonProperty("created_at") long createdAt, + @JsonProperty("updated_at") long updatedAt) { + Utils.checkNotNull(object, "object"); + Utils.checkNotNull(id, "id"); + Utils.checkNotNull(sessionId, "sessionId"); + Utils.checkNotNull(userId, "userId"); + Utils.checkNotNull(level, "level"); + Utils.checkNotNull(status, "status"); + Utils.checkNotNull(firstFactorVerifiedAt, "firstFactorVerifiedAt"); + Utils.checkNotNull(secondFactorVerifiedAt, "secondFactorVerifiedAt"); + Utils.checkNotNull(createdAt, "createdAt"); + Utils.checkNotNull(updatedAt, "updatedAt"); + this.object = object; + this.id = id; + this.sessionId = sessionId; + this.userId = userId; + this.level = level; + this.status = status; + this.firstFactorVerifiedAt = firstFactorVerifiedAt; + this.secondFactorVerifiedAt = secondFactorVerifiedAt; + this.createdAt = createdAt; + this.updatedAt = updatedAt; + } + + public Reverification( + ReverificationObject object, + String id, + String sessionId, + String userId, + Level level, + ReverificationStatus status, + long createdAt, + long updatedAt) { + this(object, id, sessionId, + userId, level, status, + Optional.empty(), Optional.empty(), createdAt, + updatedAt); + } + + /** + * String representing the object's type. Objects of the same type share the same value. + */ + @JsonIgnore + public ReverificationObject object() { + return object; + } + + @JsonIgnore + public String id() { + return id; + } + + @JsonIgnore + public String sessionId() { + return sessionId; + } + + @JsonIgnore + public String userId() { + return userId; + } + + /** + * The level used for the reverification + */ + @JsonIgnore + public Level level() { + return level; + } + + @JsonIgnore + public ReverificationStatus status() { + return status; + } + + /** + * Unix timestamp (ms) of the first factor verification, or null if not verified. + */ + @JsonIgnore + public Optional firstFactorVerifiedAt() { + return firstFactorVerifiedAt; + } + + /** + * Unix timestamp (ms) of the second factor verification, or null if not verified. + */ + @JsonIgnore + public Optional secondFactorVerifiedAt() { + return secondFactorVerifiedAt; + } + + /** + * Unix timestamp of creation. + */ + @JsonIgnore + public long createdAt() { + return createdAt; + } + + /** + * Unix timestamp of last update. + */ + @JsonIgnore + public long updatedAt() { + return updatedAt; + } + + public static Builder builder() { + return new Builder(); + } + + + /** + * String representing the object's type. Objects of the same type share the same value. + */ + public Reverification withObject(ReverificationObject object) { + Utils.checkNotNull(object, "object"); + this.object = object; + return this; + } + + public Reverification withId(String id) { + Utils.checkNotNull(id, "id"); + this.id = id; + return this; + } + + public Reverification withSessionId(String sessionId) { + Utils.checkNotNull(sessionId, "sessionId"); + this.sessionId = sessionId; + return this; + } + + public Reverification withUserId(String userId) { + Utils.checkNotNull(userId, "userId"); + this.userId = userId; + return this; + } + + /** + * The level used for the reverification + */ + public Reverification withLevel(Level level) { + Utils.checkNotNull(level, "level"); + this.level = level; + return this; + } + + public Reverification withStatus(ReverificationStatus status) { + Utils.checkNotNull(status, "status"); + this.status = status; + return this; + } + + /** + * Unix timestamp (ms) of the first factor verification, or null if not verified. + */ + public Reverification withFirstFactorVerifiedAt(long firstFactorVerifiedAt) { + Utils.checkNotNull(firstFactorVerifiedAt, "firstFactorVerifiedAt"); + this.firstFactorVerifiedAt = Optional.ofNullable(firstFactorVerifiedAt); + return this; + } + + + /** + * Unix timestamp (ms) of the first factor verification, or null if not verified. + */ + public Reverification withFirstFactorVerifiedAt(Optional firstFactorVerifiedAt) { + Utils.checkNotNull(firstFactorVerifiedAt, "firstFactorVerifiedAt"); + this.firstFactorVerifiedAt = firstFactorVerifiedAt; + return this; + } + + /** + * Unix timestamp (ms) of the second factor verification, or null if not verified. + */ + public Reverification withSecondFactorVerifiedAt(long secondFactorVerifiedAt) { + Utils.checkNotNull(secondFactorVerifiedAt, "secondFactorVerifiedAt"); + this.secondFactorVerifiedAt = Optional.ofNullable(secondFactorVerifiedAt); + return this; + } + + + /** + * Unix timestamp (ms) of the second factor verification, or null if not verified. + */ + public Reverification withSecondFactorVerifiedAt(Optional secondFactorVerifiedAt) { + Utils.checkNotNull(secondFactorVerifiedAt, "secondFactorVerifiedAt"); + this.secondFactorVerifiedAt = secondFactorVerifiedAt; + return this; + } + + /** + * Unix timestamp of creation. + */ + public Reverification withCreatedAt(long createdAt) { + Utils.checkNotNull(createdAt, "createdAt"); + this.createdAt = createdAt; + return this; + } + + /** + * Unix timestamp of last update. + */ + public Reverification withUpdatedAt(long updatedAt) { + Utils.checkNotNull(updatedAt, "updatedAt"); + this.updatedAt = updatedAt; + return this; + } + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + Reverification other = (Reverification) o; + return + Utils.enhancedDeepEquals(this.object, other.object) && + Utils.enhancedDeepEquals(this.id, other.id) && + Utils.enhancedDeepEquals(this.sessionId, other.sessionId) && + Utils.enhancedDeepEquals(this.userId, other.userId) && + Utils.enhancedDeepEquals(this.level, other.level) && + Utils.enhancedDeepEquals(this.status, other.status) && + Utils.enhancedDeepEquals(this.firstFactorVerifiedAt, other.firstFactorVerifiedAt) && + Utils.enhancedDeepEquals(this.secondFactorVerifiedAt, other.secondFactorVerifiedAt) && + Utils.enhancedDeepEquals(this.createdAt, other.createdAt) && + Utils.enhancedDeepEquals(this.updatedAt, other.updatedAt); + } + + @Override + public int hashCode() { + return Utils.enhancedHash( + object, id, sessionId, + userId, level, status, + firstFactorVerifiedAt, secondFactorVerifiedAt, createdAt, + updatedAt); + } + + @Override + public String toString() { + return Utils.toString(Reverification.class, + "object", object, + "id", id, + "sessionId", sessionId, + "userId", userId, + "level", level, + "status", status, + "firstFactorVerifiedAt", firstFactorVerifiedAt, + "secondFactorVerifiedAt", secondFactorVerifiedAt, + "createdAt", createdAt, + "updatedAt", updatedAt); + } + + @SuppressWarnings("UnusedReturnValue") + public final static class Builder { + + private ReverificationObject object; + + private String id; + + private String sessionId; + + private String userId; + + private Level level; + + private ReverificationStatus status; + + private Optional firstFactorVerifiedAt = Optional.empty(); + + private Optional secondFactorVerifiedAt = Optional.empty(); + + private Long createdAt; + + private Long updatedAt; + + private Builder() { + // force use of static builder() method + } + + + /** + * String representing the object's type. Objects of the same type share the same value. + */ + public Builder object(ReverificationObject object) { + Utils.checkNotNull(object, "object"); + this.object = object; + return this; + } + + + public Builder id(String id) { + Utils.checkNotNull(id, "id"); + this.id = id; + return this; + } + + + public Builder sessionId(String sessionId) { + Utils.checkNotNull(sessionId, "sessionId"); + this.sessionId = sessionId; + return this; + } + + + public Builder userId(String userId) { + Utils.checkNotNull(userId, "userId"); + this.userId = userId; + return this; + } + + + /** + * The level used for the reverification + */ + public Builder level(Level level) { + Utils.checkNotNull(level, "level"); + this.level = level; + return this; + } + + + public Builder status(ReverificationStatus status) { + Utils.checkNotNull(status, "status"); + this.status = status; + return this; + } + + + /** + * Unix timestamp (ms) of the first factor verification, or null if not verified. + */ + public Builder firstFactorVerifiedAt(long firstFactorVerifiedAt) { + Utils.checkNotNull(firstFactorVerifiedAt, "firstFactorVerifiedAt"); + this.firstFactorVerifiedAt = Optional.ofNullable(firstFactorVerifiedAt); + return this; + } + + /** + * Unix timestamp (ms) of the first factor verification, or null if not verified. + */ + public Builder firstFactorVerifiedAt(Optional firstFactorVerifiedAt) { + Utils.checkNotNull(firstFactorVerifiedAt, "firstFactorVerifiedAt"); + this.firstFactorVerifiedAt = firstFactorVerifiedAt; + return this; + } + + + /** + * Unix timestamp (ms) of the second factor verification, or null if not verified. + */ + public Builder secondFactorVerifiedAt(long secondFactorVerifiedAt) { + Utils.checkNotNull(secondFactorVerifiedAt, "secondFactorVerifiedAt"); + this.secondFactorVerifiedAt = Optional.ofNullable(secondFactorVerifiedAt); + return this; + } + + /** + * Unix timestamp (ms) of the second factor verification, or null if not verified. + */ + public Builder secondFactorVerifiedAt(Optional secondFactorVerifiedAt) { + Utils.checkNotNull(secondFactorVerifiedAt, "secondFactorVerifiedAt"); + this.secondFactorVerifiedAt = secondFactorVerifiedAt; + return this; + } + + + /** + * Unix timestamp of creation. + */ + public Builder createdAt(long createdAt) { + Utils.checkNotNull(createdAt, "createdAt"); + this.createdAt = createdAt; + return this; + } + + + /** + * Unix timestamp of last update. + */ + public Builder updatedAt(long updatedAt) { + Utils.checkNotNull(updatedAt, "updatedAt"); + this.updatedAt = updatedAt; + return this; + } + + public Reverification build() { + + return new Reverification( + object, id, sessionId, + userId, level, status, + firstFactorVerifiedAt, secondFactorVerifiedAt, createdAt, + updatedAt); + } + + } +} diff --git a/src/main/java/com/clerk/backend_api/models/components/ReverificationObject.java b/src/main/java/com/clerk/backend_api/models/components/ReverificationObject.java new file mode 100644 index 00000000..b7961c91 --- /dev/null +++ b/src/main/java/com/clerk/backend_api/models/components/ReverificationObject.java @@ -0,0 +1,39 @@ +/* + * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + */ +package com.clerk.backend_api.models.components; + +import com.fasterxml.jackson.annotation.JsonValue; +import java.lang.String; +import java.util.Objects; +import java.util.Optional; + +/** + * ReverificationObject + * + *

String representing the object's type. Objects of the same type share the same value. + */ +public enum ReverificationObject { + REVERIFICATION("reverification"); + + @JsonValue + private final String value; + + ReverificationObject(String value) { + this.value = value; + } + + public String value() { + return value; + } + + public static Optional fromValue(String value) { + for (ReverificationObject o: ReverificationObject.values()) { + if (Objects.deepEquals(o.value, value)) { + return Optional.of(o); + } + } + return Optional.empty(); + } +} + diff --git a/src/main/java/com/clerk/backend_api/models/components/ReverificationStatus.java b/src/main/java/com/clerk/backend_api/models/components/ReverificationStatus.java new file mode 100644 index 00000000..c2e5b25b --- /dev/null +++ b/src/main/java/com/clerk/backend_api/models/components/ReverificationStatus.java @@ -0,0 +1,36 @@ +/* + * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + */ +package com.clerk.backend_api.models.components; + +import com.fasterxml.jackson.annotation.JsonValue; +import java.lang.String; +import java.util.Objects; +import java.util.Optional; + +public enum ReverificationStatus { + NEEDS_FIRST_FACTOR("needs_first_factor"), + NEEDS_SECOND_FACTOR("needs_second_factor"), + COMPLETE("complete"); + + @JsonValue + private final String value; + + ReverificationStatus(String value) { + this.value = value; + } + + public String value() { + return value; + } + + public static Optional fromValue(String value) { + for (ReverificationStatus o: ReverificationStatus.values()) { + if (Objects.deepEquals(o.value, value)) { + return Optional.of(o); + } + } + return Optional.empty(); + } +} + diff --git a/src/main/java/com/clerk/backend_api/models/components/SCIMUserMetadata.java b/src/main/java/com/clerk/backend_api/models/components/SCIMUserMetadata.java new file mode 100644 index 00000000..58925943 --- /dev/null +++ b/src/main/java/com/clerk/backend_api/models/components/SCIMUserMetadata.java @@ -0,0 +1,430 @@ +/* + * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + */ +package com.clerk.backend_api.models.components; + +import com.clerk.backend_api.utils.Utils; +import com.fasterxml.jackson.annotation.JsonCreator; +import com.fasterxml.jackson.annotation.JsonIgnore; +import com.fasterxml.jackson.annotation.JsonInclude.Include; +import com.fasterxml.jackson.annotation.JsonInclude; +import com.fasterxml.jackson.annotation.JsonProperty; +import java.lang.Boolean; +import java.lang.Override; +import java.lang.String; +import java.lang.SuppressWarnings; +import java.util.List; +import java.util.Optional; + +/** + * SCIMUserMetadata + * + *

Metadata describing a user's linkage to a directory. Included in user responses when directory data + * is requested, and in directory-triggered user webhooks. Its absence does not necessarily mean the + * user is not managed by a directory. + */ +public class SCIMUserMetadata { + /** + * The user's resource ID in this directory. + */ + @JsonProperty("id") + private String id; + + + @JsonProperty("directory_name") + private String directoryName; + + + @JsonProperty("provider") + private String provider; + + + @JsonInclude(Include.ALWAYS) + @JsonProperty("enterprise_connection_id") + private Optional enterpriseConnectionId; + + /** + * Omitted when groups were not loaded; an empty array means no group memberships. + */ + @JsonInclude(Include.NON_ABSENT) + @JsonProperty("groups") + private Optional> groups; + + /** + * The ID of the directory the user is provisioned from. + */ + @JsonProperty("directory_id") + private String directoryId; + + /** + * Whether the directory is currently enabled. + */ + @JsonProperty("directory_enabled") + private boolean directoryEnabled; + + /** + * The user's external ID as reported by the directory, if any. + */ + @JsonInclude(Include.ALWAYS) + @JsonProperty("external_id") + private Optional externalId; + + @JsonCreator + public SCIMUserMetadata( + @JsonProperty("id") String id, + @JsonProperty("directory_name") String directoryName, + @JsonProperty("provider") String provider, + @JsonProperty("enterprise_connection_id") Optional enterpriseConnectionId, + @JsonProperty("groups") Optional> groups, + @JsonProperty("directory_id") String directoryId, + @JsonProperty("directory_enabled") boolean directoryEnabled, + @JsonProperty("external_id") Optional externalId) { + Utils.checkNotNull(id, "id"); + Utils.checkNotNull(directoryName, "directoryName"); + Utils.checkNotNull(provider, "provider"); + Utils.checkNotNull(enterpriseConnectionId, "enterpriseConnectionId"); + Utils.checkNotNull(groups, "groups"); + Utils.checkNotNull(directoryId, "directoryId"); + Utils.checkNotNull(directoryEnabled, "directoryEnabled"); + Utils.checkNotNull(externalId, "externalId"); + this.id = id; + this.directoryName = directoryName; + this.provider = provider; + this.enterpriseConnectionId = enterpriseConnectionId; + this.groups = groups; + this.directoryId = directoryId; + this.directoryEnabled = directoryEnabled; + this.externalId = externalId; + } + + public SCIMUserMetadata( + String id, + String directoryName, + String provider, + String directoryId, + boolean directoryEnabled) { + this(id, directoryName, provider, + Optional.empty(), Optional.empty(), directoryId, + directoryEnabled, Optional.empty()); + } + + /** + * The user's resource ID in this directory. + */ + @JsonIgnore + public String id() { + return id; + } + + @JsonIgnore + public String directoryName() { + return directoryName; + } + + @JsonIgnore + public String provider() { + return provider; + } + + @JsonIgnore + public Optional enterpriseConnectionId() { + return enterpriseConnectionId; + } + + /** + * Omitted when groups were not loaded; an empty array means no group memberships. + */ + @SuppressWarnings("unchecked") + @JsonIgnore + public Optional> groups() { + return (Optional>) groups; + } + + /** + * The ID of the directory the user is provisioned from. + */ + @JsonIgnore + public String directoryId() { + return directoryId; + } + + /** + * Whether the directory is currently enabled. + */ + @JsonIgnore + public boolean directoryEnabled() { + return directoryEnabled; + } + + /** + * The user's external ID as reported by the directory, if any. + */ + @JsonIgnore + public Optional externalId() { + return externalId; + } + + public static Builder builder() { + return new Builder(); + } + + + /** + * The user's resource ID in this directory. + */ + public SCIMUserMetadata withId(String id) { + Utils.checkNotNull(id, "id"); + this.id = id; + return this; + } + + public SCIMUserMetadata withDirectoryName(String directoryName) { + Utils.checkNotNull(directoryName, "directoryName"); + this.directoryName = directoryName; + return this; + } + + public SCIMUserMetadata withProvider(String provider) { + Utils.checkNotNull(provider, "provider"); + this.provider = provider; + return this; + } + + public SCIMUserMetadata withEnterpriseConnectionId(String enterpriseConnectionId) { + Utils.checkNotNull(enterpriseConnectionId, "enterpriseConnectionId"); + this.enterpriseConnectionId = Optional.ofNullable(enterpriseConnectionId); + return this; + } + + + public SCIMUserMetadata withEnterpriseConnectionId(Optional enterpriseConnectionId) { + Utils.checkNotNull(enterpriseConnectionId, "enterpriseConnectionId"); + this.enterpriseConnectionId = enterpriseConnectionId; + return this; + } + + /** + * Omitted when groups were not loaded; an empty array means no group memberships. + */ + public SCIMUserMetadata withGroups(List groups) { + Utils.checkNotNull(groups, "groups"); + this.groups = Optional.ofNullable(groups); + return this; + } + + + /** + * Omitted when groups were not loaded; an empty array means no group memberships. + */ + public SCIMUserMetadata withGroups(Optional> groups) { + Utils.checkNotNull(groups, "groups"); + this.groups = groups; + return this; + } + + /** + * The ID of the directory the user is provisioned from. + */ + public SCIMUserMetadata withDirectoryId(String directoryId) { + Utils.checkNotNull(directoryId, "directoryId"); + this.directoryId = directoryId; + return this; + } + + /** + * Whether the directory is currently enabled. + */ + public SCIMUserMetadata withDirectoryEnabled(boolean directoryEnabled) { + Utils.checkNotNull(directoryEnabled, "directoryEnabled"); + this.directoryEnabled = directoryEnabled; + return this; + } + + /** + * The user's external ID as reported by the directory, if any. + */ + public SCIMUserMetadata withExternalId(String externalId) { + Utils.checkNotNull(externalId, "externalId"); + this.externalId = Optional.ofNullable(externalId); + return this; + } + + + /** + * The user's external ID as reported by the directory, if any. + */ + public SCIMUserMetadata withExternalId(Optional externalId) { + Utils.checkNotNull(externalId, "externalId"); + this.externalId = externalId; + return this; + } + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + SCIMUserMetadata other = (SCIMUserMetadata) o; + return + Utils.enhancedDeepEquals(this.id, other.id) && + Utils.enhancedDeepEquals(this.directoryName, other.directoryName) && + Utils.enhancedDeepEquals(this.provider, other.provider) && + Utils.enhancedDeepEquals(this.enterpriseConnectionId, other.enterpriseConnectionId) && + Utils.enhancedDeepEquals(this.groups, other.groups) && + Utils.enhancedDeepEquals(this.directoryId, other.directoryId) && + Utils.enhancedDeepEquals(this.directoryEnabled, other.directoryEnabled) && + Utils.enhancedDeepEquals(this.externalId, other.externalId); + } + + @Override + public int hashCode() { + return Utils.enhancedHash( + id, directoryName, provider, + enterpriseConnectionId, groups, directoryId, + directoryEnabled, externalId); + } + + @Override + public String toString() { + return Utils.toString(SCIMUserMetadata.class, + "id", id, + "directoryName", directoryName, + "provider", provider, + "enterpriseConnectionId", enterpriseConnectionId, + "groups", groups, + "directoryId", directoryId, + "directoryEnabled", directoryEnabled, + "externalId", externalId); + } + + @SuppressWarnings("UnusedReturnValue") + public final static class Builder { + + private String id; + + private String directoryName; + + private String provider; + + private Optional enterpriseConnectionId = Optional.empty(); + + private Optional> groups = Optional.empty(); + + private String directoryId; + + private Boolean directoryEnabled; + + private Optional externalId = Optional.empty(); + + private Builder() { + // force use of static builder() method + } + + + /** + * The user's resource ID in this directory. + */ + public Builder id(String id) { + Utils.checkNotNull(id, "id"); + this.id = id; + return this; + } + + + public Builder directoryName(String directoryName) { + Utils.checkNotNull(directoryName, "directoryName"); + this.directoryName = directoryName; + return this; + } + + + public Builder provider(String provider) { + Utils.checkNotNull(provider, "provider"); + this.provider = provider; + return this; + } + + + public Builder enterpriseConnectionId(String enterpriseConnectionId) { + Utils.checkNotNull(enterpriseConnectionId, "enterpriseConnectionId"); + this.enterpriseConnectionId = Optional.ofNullable(enterpriseConnectionId); + return this; + } + + public Builder enterpriseConnectionId(Optional enterpriseConnectionId) { + Utils.checkNotNull(enterpriseConnectionId, "enterpriseConnectionId"); + this.enterpriseConnectionId = enterpriseConnectionId; + return this; + } + + + /** + * Omitted when groups were not loaded; an empty array means no group memberships. + */ + public Builder groups(List groups) { + Utils.checkNotNull(groups, "groups"); + this.groups = Optional.ofNullable(groups); + return this; + } + + /** + * Omitted when groups were not loaded; an empty array means no group memberships. + */ + public Builder groups(Optional> groups) { + Utils.checkNotNull(groups, "groups"); + this.groups = groups; + return this; + } + + + /** + * The ID of the directory the user is provisioned from. + */ + public Builder directoryId(String directoryId) { + Utils.checkNotNull(directoryId, "directoryId"); + this.directoryId = directoryId; + return this; + } + + + /** + * Whether the directory is currently enabled. + */ + public Builder directoryEnabled(boolean directoryEnabled) { + Utils.checkNotNull(directoryEnabled, "directoryEnabled"); + this.directoryEnabled = directoryEnabled; + return this; + } + + + /** + * The user's external ID as reported by the directory, if any. + */ + public Builder externalId(String externalId) { + Utils.checkNotNull(externalId, "externalId"); + this.externalId = Optional.ofNullable(externalId); + return this; + } + + /** + * The user's external ID as reported by the directory, if any. + */ + public Builder externalId(Optional externalId) { + Utils.checkNotNull(externalId, "externalId"); + this.externalId = externalId; + return this; + } + + public SCIMUserMetadata build() { + + return new SCIMUserMetadata( + id, directoryName, provider, + enterpriseConnectionId, groups, directoryId, + directoryEnabled, externalId); + } + + } +} diff --git a/src/main/java/com/clerk/backend_api/models/components/Scim.java b/src/main/java/com/clerk/backend_api/models/components/Scim.java index a7742dda..eefd32c5 100644 --- a/src/main/java/com/clerk/backend_api/models/components/Scim.java +++ b/src/main/java/com/clerk/backend_api/models/components/Scim.java @@ -10,18 +10,48 @@ import com.fasterxml.jackson.annotation.JsonInclude; import com.fasterxml.jackson.annotation.JsonProperty; import java.lang.Boolean; +import java.lang.Deprecated; import java.lang.Override; import java.lang.String; +import java.lang.SuppressWarnings; +import java.util.List; import java.util.Optional; /** * Scim * - *

Metadata describing a user's linkage to a directory. This object is only delivered on `user.created` - * and `user.updated` webhook events, and only when the user is provisioned through a directory. Its - * absence does not necessarily mean the user is not managed by a directory. + *

Alias of directory. Use directories for all links. + * + * @deprecated class: This will be removed in a future release, please migrate away from it as soon as possible. */ +@Deprecated public class Scim { + /** + * The user's resource ID in this directory. + */ + @JsonProperty("id") + private String id; + + + @JsonProperty("directory_name") + private String directoryName; + + + @JsonProperty("provider") + private String provider; + + + @JsonInclude(Include.ALWAYS) + @JsonProperty("enterprise_connection_id") + private Optional enterpriseConnectionId; + + /** + * Omitted when groups were not loaded; an empty array means no group memberships. + */ + @JsonInclude(Include.NON_ABSENT) + @JsonProperty("groups") + private Optional> groups; + /** * The ID of the directory the user is provisioned from. */ @@ -29,11 +59,10 @@ public class Scim { private String directoryId; /** - * Whether the directory is currently enabled. Omitted when false. + * Whether the directory is currently enabled. */ - @JsonInclude(Include.NON_ABSENT) @JsonProperty("directory_enabled") - private Optional directoryEnabled; + private boolean directoryEnabled; /** * The user's external ID as reported by the directory, if any. @@ -44,20 +73,73 @@ public class Scim { @JsonCreator public Scim( + @JsonProperty("id") String id, + @JsonProperty("directory_name") String directoryName, + @JsonProperty("provider") String provider, + @JsonProperty("enterprise_connection_id") Optional enterpriseConnectionId, + @JsonProperty("groups") Optional> groups, @JsonProperty("directory_id") String directoryId, - @JsonProperty("directory_enabled") Optional directoryEnabled, + @JsonProperty("directory_enabled") boolean directoryEnabled, @JsonProperty("external_id") Optional externalId) { + Utils.checkNotNull(id, "id"); + Utils.checkNotNull(directoryName, "directoryName"); + Utils.checkNotNull(provider, "provider"); + Utils.checkNotNull(enterpriseConnectionId, "enterpriseConnectionId"); + Utils.checkNotNull(groups, "groups"); Utils.checkNotNull(directoryId, "directoryId"); Utils.checkNotNull(directoryEnabled, "directoryEnabled"); Utils.checkNotNull(externalId, "externalId"); + this.id = id; + this.directoryName = directoryName; + this.provider = provider; + this.enterpriseConnectionId = enterpriseConnectionId; + this.groups = groups; this.directoryId = directoryId; this.directoryEnabled = directoryEnabled; this.externalId = externalId; } public Scim( - String directoryId) { - this(directoryId, Optional.empty(), Optional.empty()); + String id, + String directoryName, + String provider, + String directoryId, + boolean directoryEnabled) { + this(id, directoryName, provider, + Optional.empty(), Optional.empty(), directoryId, + directoryEnabled, Optional.empty()); + } + + /** + * The user's resource ID in this directory. + */ + @JsonIgnore + public String id() { + return id; + } + + @JsonIgnore + public String directoryName() { + return directoryName; + } + + @JsonIgnore + public String provider() { + return provider; + } + + @JsonIgnore + public Optional enterpriseConnectionId() { + return enterpriseConnectionId; + } + + /** + * Omitted when groups were not loaded; an empty array means no group memberships. + */ + @SuppressWarnings("unchecked") + @JsonIgnore + public Optional> groups() { + return (Optional>) groups; } /** @@ -69,10 +151,10 @@ public String directoryId() { } /** - * Whether the directory is currently enabled. Omitted when false. + * Whether the directory is currently enabled. */ @JsonIgnore - public Optional directoryEnabled() { + public boolean directoryEnabled() { return directoryEnabled; } @@ -90,28 +172,71 @@ public static Builder builder() { /** - * The ID of the directory the user is provisioned from. + * The user's resource ID in this directory. */ - public Scim withDirectoryId(String directoryId) { - Utils.checkNotNull(directoryId, "directoryId"); - this.directoryId = directoryId; + public Scim withId(String id) { + Utils.checkNotNull(id, "id"); + this.id = id; + return this; + } + + public Scim withDirectoryName(String directoryName) { + Utils.checkNotNull(directoryName, "directoryName"); + this.directoryName = directoryName; + return this; + } + + public Scim withProvider(String provider) { + Utils.checkNotNull(provider, "provider"); + this.provider = provider; + return this; + } + + public Scim withEnterpriseConnectionId(String enterpriseConnectionId) { + Utils.checkNotNull(enterpriseConnectionId, "enterpriseConnectionId"); + this.enterpriseConnectionId = Optional.ofNullable(enterpriseConnectionId); + return this; + } + + + public Scim withEnterpriseConnectionId(Optional enterpriseConnectionId) { + Utils.checkNotNull(enterpriseConnectionId, "enterpriseConnectionId"); + this.enterpriseConnectionId = enterpriseConnectionId; return this; } /** - * Whether the directory is currently enabled. Omitted when false. + * Omitted when groups were not loaded; an empty array means no group memberships. */ - public Scim withDirectoryEnabled(boolean directoryEnabled) { - Utils.checkNotNull(directoryEnabled, "directoryEnabled"); - this.directoryEnabled = Optional.ofNullable(directoryEnabled); + public Scim withGroups(List groups) { + Utils.checkNotNull(groups, "groups"); + this.groups = Optional.ofNullable(groups); + return this; + } + + + /** + * Omitted when groups were not loaded; an empty array means no group memberships. + */ + public Scim withGroups(Optional> groups) { + Utils.checkNotNull(groups, "groups"); + this.groups = groups; return this; } + /** + * The ID of the directory the user is provisioned from. + */ + public Scim withDirectoryId(String directoryId) { + Utils.checkNotNull(directoryId, "directoryId"); + this.directoryId = directoryId; + return this; + } /** - * Whether the directory is currently enabled. Omitted when false. + * Whether the directory is currently enabled. */ - public Scim withDirectoryEnabled(Optional directoryEnabled) { + public Scim withDirectoryEnabled(boolean directoryEnabled) { Utils.checkNotNull(directoryEnabled, "directoryEnabled"); this.directoryEnabled = directoryEnabled; return this; @@ -146,6 +271,11 @@ public boolean equals(java.lang.Object o) { } Scim other = (Scim) o; return + Utils.enhancedDeepEquals(this.id, other.id) && + Utils.enhancedDeepEquals(this.directoryName, other.directoryName) && + Utils.enhancedDeepEquals(this.provider, other.provider) && + Utils.enhancedDeepEquals(this.enterpriseConnectionId, other.enterpriseConnectionId) && + Utils.enhancedDeepEquals(this.groups, other.groups) && Utils.enhancedDeepEquals(this.directoryId, other.directoryId) && Utils.enhancedDeepEquals(this.directoryEnabled, other.directoryEnabled) && Utils.enhancedDeepEquals(this.externalId, other.externalId); @@ -154,12 +284,19 @@ public boolean equals(java.lang.Object o) { @Override public int hashCode() { return Utils.enhancedHash( - directoryId, directoryEnabled, externalId); + id, directoryName, provider, + enterpriseConnectionId, groups, directoryId, + directoryEnabled, externalId); } @Override public String toString() { return Utils.toString(Scim.class, + "id", id, + "directoryName", directoryName, + "provider", provider, + "enterpriseConnectionId", enterpriseConnectionId, + "groups", groups, "directoryId", directoryId, "directoryEnabled", directoryEnabled, "externalId", externalId); @@ -168,9 +305,19 @@ public String toString() { @SuppressWarnings("UnusedReturnValue") public final static class Builder { + private String id; + + private String directoryName; + + private String provider; + + private Optional enterpriseConnectionId = Optional.empty(); + + private Optional> groups = Optional.empty(); + private String directoryId; - private Optional directoryEnabled = Optional.empty(); + private Boolean directoryEnabled; private Optional externalId = Optional.empty(); @@ -180,28 +327,75 @@ private Builder() { /** - * The ID of the directory the user is provisioned from. + * The user's resource ID in this directory. */ - public Builder directoryId(String directoryId) { - Utils.checkNotNull(directoryId, "directoryId"); - this.directoryId = directoryId; + public Builder id(String id) { + Utils.checkNotNull(id, "id"); + this.id = id; + return this; + } + + + public Builder directoryName(String directoryName) { + Utils.checkNotNull(directoryName, "directoryName"); + this.directoryName = directoryName; + return this; + } + + + public Builder provider(String provider) { + Utils.checkNotNull(provider, "provider"); + this.provider = provider; + return this; + } + + + public Builder enterpriseConnectionId(String enterpriseConnectionId) { + Utils.checkNotNull(enterpriseConnectionId, "enterpriseConnectionId"); + this.enterpriseConnectionId = Optional.ofNullable(enterpriseConnectionId); + return this; + } + + public Builder enterpriseConnectionId(Optional enterpriseConnectionId) { + Utils.checkNotNull(enterpriseConnectionId, "enterpriseConnectionId"); + this.enterpriseConnectionId = enterpriseConnectionId; return this; } /** - * Whether the directory is currently enabled. Omitted when false. + * Omitted when groups were not loaded; an empty array means no group memberships. */ - public Builder directoryEnabled(boolean directoryEnabled) { - Utils.checkNotNull(directoryEnabled, "directoryEnabled"); - this.directoryEnabled = Optional.ofNullable(directoryEnabled); + public Builder groups(List groups) { + Utils.checkNotNull(groups, "groups"); + this.groups = Optional.ofNullable(groups); + return this; + } + + /** + * Omitted when groups were not loaded; an empty array means no group memberships. + */ + public Builder groups(Optional> groups) { + Utils.checkNotNull(groups, "groups"); + this.groups = groups; + return this; + } + + + /** + * The ID of the directory the user is provisioned from. + */ + public Builder directoryId(String directoryId) { + Utils.checkNotNull(directoryId, "directoryId"); + this.directoryId = directoryId; return this; } + /** - * Whether the directory is currently enabled. Omitted when false. + * Whether the directory is currently enabled. */ - public Builder directoryEnabled(Optional directoryEnabled) { + public Builder directoryEnabled(boolean directoryEnabled) { Utils.checkNotNull(directoryEnabled, "directoryEnabled"); this.directoryEnabled = directoryEnabled; return this; @@ -229,7 +423,9 @@ public Builder externalId(Optional externalId) { public Scim build() { return new Scim( - directoryId, directoryEnabled, externalId); + id, directoryName, provider, + enterpriseConnectionId, groups, directoryId, + directoryEnabled, externalId); } } diff --git a/src/main/java/com/clerk/backend_api/models/components/User.java b/src/main/java/com/clerk/backend_api/models/components/User.java index 5eb46c43..fcbcb095 100644 --- a/src/main/java/com/clerk/backend_api/models/components/User.java +++ b/src/main/java/com/clerk/backend_api/models/components/User.java @@ -278,9 +278,32 @@ public class User { @JsonProperty("bypass_client_trust") private Optional bypassClientTrust; + /** + * All loaded directory links. Omitted when links were not loaded; an empty array means the user has no + * directory links. + */ + @JsonInclude(Include.NON_ABSENT) + @JsonProperty("directories") + private Optional> directories; + /** + * The most recently updated directory link. Use directories for all links. + * + * @deprecated field: This will be removed in a future release, please migrate away from it as soon as possible. + */ + @JsonInclude(Include.NON_ABSENT) + @JsonProperty("directory") + @Deprecated + private Optional directory; + + /** + * Alias of directory. Use directories for all links. + * + * @deprecated field: This will be removed in a future release, please migrate away from it as soon as possible. + */ @JsonInclude(Include.NON_ABSENT) @JsonProperty("scim") + @Deprecated private JsonNullable scim; @JsonCreator @@ -330,6 +353,8 @@ public User( @JsonProperty("last_active_at") Optional lastActiveAt, @JsonProperty("legal_accepted_at") Optional legalAcceptedAt, @JsonProperty("bypass_client_trust") Optional bypassClientTrust, + @JsonProperty("directories") Optional> directories, + @JsonProperty("directory") Optional directory, @JsonProperty("scim") JsonNullable scim) { Utils.checkNotNull(id, "id"); Utils.checkNotNull(object, "object"); @@ -377,6 +402,8 @@ public User( Utils.checkNotNull(lastActiveAt, "lastActiveAt"); Utils.checkNotNull(legalAcceptedAt, "legalAcceptedAt"); Utils.checkNotNull(bypassClientTrust, "bypassClientTrust"); + Utils.checkNotNull(directories, "directories"); + Utils.checkNotNull(directory, "directory"); Utils.checkNotNull(scim, "scim"); this.id = id; this.object = object; @@ -423,6 +450,8 @@ public User( this.lastActiveAt = lastActiveAt; this.legalAcceptedAt = legalAcceptedAt; this.bypassClientTrust = bypassClientTrust; + this.directories = directories; + this.directory = directory; this.scim = scim; } @@ -463,7 +492,7 @@ public User( Optional.empty(), updatedAt, createdAt, deleteSelfEnabled, createOrganizationEnabled, JsonNullable.undefined(), Optional.empty(), Optional.empty(), Optional.empty(), - JsonNullable.undefined()); + Optional.empty(), Optional.empty(), JsonNullable.undefined()); } @JsonIgnore @@ -758,6 +787,34 @@ public Optional bypassClientTrust() { return bypassClientTrust; } + /** + * All loaded directory links. Omitted when links were not loaded; an empty array means the user has no + * directory links. + */ + @SuppressWarnings("unchecked") + @JsonIgnore + public Optional> directories() { + return (Optional>) directories; + } + + /** + * The most recently updated directory link. Use directories for all links. + * + * @deprecated field: This will be removed in a future release, please migrate away from it as soon as possible. + */ + @Deprecated + @SuppressWarnings("unchecked") + @JsonIgnore + public Optional directory() { + return (Optional) directory; + } + + /** + * Alias of directory. Use directories for all links. + * + * @deprecated field: This will be removed in a future release, please migrate away from it as soon as possible. + */ + @Deprecated @SuppressWarnings("unchecked") @JsonIgnore public JsonNullable scim() { @@ -1310,12 +1367,70 @@ public User withBypassClientTrust(Optional bypassClientTrust) { return this; } + /** + * All loaded directory links. Omitted when links were not loaded; an empty array means the user has no + * directory links. + */ + public User withDirectories(List directories) { + Utils.checkNotNull(directories, "directories"); + this.directories = Optional.ofNullable(directories); + return this; + } + + + /** + * All loaded directory links. Omitted when links were not loaded; an empty array means the user has no + * directory links. + */ + public User withDirectories(Optional> directories) { + Utils.checkNotNull(directories, "directories"); + this.directories = directories; + return this; + } + + /** + * The most recently updated directory link. Use directories for all links. + * + * @deprecated field: This will be removed in a future release, please migrate away from it as soon as possible. + */ + @Deprecated + public User withDirectory(UserDirectory directory) { + Utils.checkNotNull(directory, "directory"); + this.directory = Optional.ofNullable(directory); + return this; + } + + + /** + * The most recently updated directory link. Use directories for all links. + * + * @deprecated field: This will be removed in a future release, please migrate away from it as soon as possible. + */ + @Deprecated + public User withDirectory(Optional directory) { + Utils.checkNotNull(directory, "directory"); + this.directory = directory; + return this; + } + + /** + * Alias of directory. Use directories for all links. + * + * @deprecated field: This will be removed in a future release, please migrate away from it as soon as possible. + */ + @Deprecated public User withScim(Scim scim) { Utils.checkNotNull(scim, "scim"); this.scim = JsonNullable.of(scim); return this; } + /** + * Alias of directory. Use directories for all links. + * + * @deprecated field: This will be removed in a future release, please migrate away from it as soon as possible. + */ + @Deprecated public User withScim(JsonNullable scim) { Utils.checkNotNull(scim, "scim"); this.scim = scim; @@ -1377,6 +1492,8 @@ public boolean equals(java.lang.Object o) { Utils.enhancedDeepEquals(this.lastActiveAt, other.lastActiveAt) && Utils.enhancedDeepEquals(this.legalAcceptedAt, other.legalAcceptedAt) && Utils.enhancedDeepEquals(this.bypassClientTrust, other.bypassClientTrust) && + Utils.enhancedDeepEquals(this.directories, other.directories) && + Utils.enhancedDeepEquals(this.directory, other.directory) && Utils.enhancedDeepEquals(this.scim, other.scim); } @@ -1398,7 +1515,7 @@ public int hashCode() { verificationAttemptsRemaining, updatedAt, createdAt, deleteSelfEnabled, createOrganizationEnabled, createOrganizationsLimit, lastActiveAt, legalAcceptedAt, bypassClientTrust, - scim); + directories, directory, scim); } @Override @@ -1449,6 +1566,8 @@ public String toString() { "lastActiveAt", lastActiveAt, "legalAcceptedAt", legalAcceptedAt, "bypassClientTrust", bypassClientTrust, + "directories", directories, + "directory", directory, "scim", scim); } @@ -1546,6 +1665,12 @@ public final static class Builder { private Optional bypassClientTrust; + private Optional> directories = Optional.empty(); + + @Deprecated + private Optional directory = Optional.empty(); + + @Deprecated private JsonNullable scim = JsonNullable.undefined(); private Builder() { @@ -2119,12 +2244,70 @@ public Builder bypassClientTrust(Optional bypassClientTrust) { } + /** + * All loaded directory links. Omitted when links were not loaded; an empty array means the user has no + * directory links. + */ + public Builder directories(List directories) { + Utils.checkNotNull(directories, "directories"); + this.directories = Optional.ofNullable(directories); + return this; + } + + /** + * All loaded directory links. Omitted when links were not loaded; an empty array means the user has no + * directory links. + */ + public Builder directories(Optional> directories) { + Utils.checkNotNull(directories, "directories"); + this.directories = directories; + return this; + } + + + /** + * The most recently updated directory link. Use directories for all links. + * + * @deprecated field: This will be removed in a future release, please migrate away from it as soon as possible. + */ + @Deprecated + public Builder directory(UserDirectory directory) { + Utils.checkNotNull(directory, "directory"); + this.directory = Optional.ofNullable(directory); + return this; + } + + /** + * The most recently updated directory link. Use directories for all links. + * + * @deprecated field: This will be removed in a future release, please migrate away from it as soon as possible. + */ + @Deprecated + public Builder directory(Optional directory) { + Utils.checkNotNull(directory, "directory"); + this.directory = directory; + return this; + } + + + /** + * Alias of directory. Use directories for all links. + * + * @deprecated field: This will be removed in a future release, please migrate away from it as soon as possible. + */ + @Deprecated public Builder scim(Scim scim) { Utils.checkNotNull(scim, "scim"); this.scim = JsonNullable.of(scim); return this; } + /** + * Alias of directory. Use directories for all links. + * + * @deprecated field: This will be removed in a future release, please migrate away from it as soon as possible. + */ + @Deprecated public Builder scim(JsonNullable scim) { Utils.checkNotNull(scim, "scim"); this.scim = scim; @@ -2152,7 +2335,7 @@ public User build() { verificationAttemptsRemaining, updatedAt, createdAt, deleteSelfEnabled, createOrganizationEnabled, createOrganizationsLimit, lastActiveAt, legalAcceptedAt, bypassClientTrust, - scim); + directories, directory, scim); } diff --git a/src/main/java/com/clerk/backend_api/models/components/UserDirectory.java b/src/main/java/com/clerk/backend_api/models/components/UserDirectory.java new file mode 100644 index 00000000..32fb0b49 --- /dev/null +++ b/src/main/java/com/clerk/backend_api/models/components/UserDirectory.java @@ -0,0 +1,432 @@ +/* + * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + */ +package com.clerk.backend_api.models.components; + +import com.clerk.backend_api.utils.Utils; +import com.fasterxml.jackson.annotation.JsonCreator; +import com.fasterxml.jackson.annotation.JsonIgnore; +import com.fasterxml.jackson.annotation.JsonInclude.Include; +import com.fasterxml.jackson.annotation.JsonInclude; +import com.fasterxml.jackson.annotation.JsonProperty; +import java.lang.Boolean; +import java.lang.Deprecated; +import java.lang.Override; +import java.lang.String; +import java.lang.SuppressWarnings; +import java.util.List; +import java.util.Optional; + +/** + * UserDirectory + * + *

The most recently updated directory link. Use directories for all links. + * + * @deprecated class: This will be removed in a future release, please migrate away from it as soon as possible. + */ +@Deprecated +public class UserDirectory { + /** + * The user's resource ID in this directory. + */ + @JsonProperty("id") + private String id; + + + @JsonProperty("directory_name") + private String directoryName; + + + @JsonProperty("provider") + private String provider; + + + @JsonInclude(Include.ALWAYS) + @JsonProperty("enterprise_connection_id") + private Optional enterpriseConnectionId; + + /** + * Omitted when groups were not loaded; an empty array means no group memberships. + */ + @JsonInclude(Include.NON_ABSENT) + @JsonProperty("groups") + private Optional> groups; + + /** + * The ID of the directory the user is provisioned from. + */ + @JsonProperty("directory_id") + private String directoryId; + + /** + * Whether the directory is currently enabled. + */ + @JsonProperty("directory_enabled") + private boolean directoryEnabled; + + /** + * The user's external ID as reported by the directory, if any. + */ + @JsonInclude(Include.ALWAYS) + @JsonProperty("external_id") + private Optional externalId; + + @JsonCreator + public UserDirectory( + @JsonProperty("id") String id, + @JsonProperty("directory_name") String directoryName, + @JsonProperty("provider") String provider, + @JsonProperty("enterprise_connection_id") Optional enterpriseConnectionId, + @JsonProperty("groups") Optional> groups, + @JsonProperty("directory_id") String directoryId, + @JsonProperty("directory_enabled") boolean directoryEnabled, + @JsonProperty("external_id") Optional externalId) { + Utils.checkNotNull(id, "id"); + Utils.checkNotNull(directoryName, "directoryName"); + Utils.checkNotNull(provider, "provider"); + Utils.checkNotNull(enterpriseConnectionId, "enterpriseConnectionId"); + Utils.checkNotNull(groups, "groups"); + Utils.checkNotNull(directoryId, "directoryId"); + Utils.checkNotNull(directoryEnabled, "directoryEnabled"); + Utils.checkNotNull(externalId, "externalId"); + this.id = id; + this.directoryName = directoryName; + this.provider = provider; + this.enterpriseConnectionId = enterpriseConnectionId; + this.groups = groups; + this.directoryId = directoryId; + this.directoryEnabled = directoryEnabled; + this.externalId = externalId; + } + + public UserDirectory( + String id, + String directoryName, + String provider, + String directoryId, + boolean directoryEnabled) { + this(id, directoryName, provider, + Optional.empty(), Optional.empty(), directoryId, + directoryEnabled, Optional.empty()); + } + + /** + * The user's resource ID in this directory. + */ + @JsonIgnore + public String id() { + return id; + } + + @JsonIgnore + public String directoryName() { + return directoryName; + } + + @JsonIgnore + public String provider() { + return provider; + } + + @JsonIgnore + public Optional enterpriseConnectionId() { + return enterpriseConnectionId; + } + + /** + * Omitted when groups were not loaded; an empty array means no group memberships. + */ + @SuppressWarnings("unchecked") + @JsonIgnore + public Optional> groups() { + return (Optional>) groups; + } + + /** + * The ID of the directory the user is provisioned from. + */ + @JsonIgnore + public String directoryId() { + return directoryId; + } + + /** + * Whether the directory is currently enabled. + */ + @JsonIgnore + public boolean directoryEnabled() { + return directoryEnabled; + } + + /** + * The user's external ID as reported by the directory, if any. + */ + @JsonIgnore + public Optional externalId() { + return externalId; + } + + public static Builder builder() { + return new Builder(); + } + + + /** + * The user's resource ID in this directory. + */ + public UserDirectory withId(String id) { + Utils.checkNotNull(id, "id"); + this.id = id; + return this; + } + + public UserDirectory withDirectoryName(String directoryName) { + Utils.checkNotNull(directoryName, "directoryName"); + this.directoryName = directoryName; + return this; + } + + public UserDirectory withProvider(String provider) { + Utils.checkNotNull(provider, "provider"); + this.provider = provider; + return this; + } + + public UserDirectory withEnterpriseConnectionId(String enterpriseConnectionId) { + Utils.checkNotNull(enterpriseConnectionId, "enterpriseConnectionId"); + this.enterpriseConnectionId = Optional.ofNullable(enterpriseConnectionId); + return this; + } + + + public UserDirectory withEnterpriseConnectionId(Optional enterpriseConnectionId) { + Utils.checkNotNull(enterpriseConnectionId, "enterpriseConnectionId"); + this.enterpriseConnectionId = enterpriseConnectionId; + return this; + } + + /** + * Omitted when groups were not loaded; an empty array means no group memberships. + */ + public UserDirectory withGroups(List groups) { + Utils.checkNotNull(groups, "groups"); + this.groups = Optional.ofNullable(groups); + return this; + } + + + /** + * Omitted when groups were not loaded; an empty array means no group memberships. + */ + public UserDirectory withGroups(Optional> groups) { + Utils.checkNotNull(groups, "groups"); + this.groups = groups; + return this; + } + + /** + * The ID of the directory the user is provisioned from. + */ + public UserDirectory withDirectoryId(String directoryId) { + Utils.checkNotNull(directoryId, "directoryId"); + this.directoryId = directoryId; + return this; + } + + /** + * Whether the directory is currently enabled. + */ + public UserDirectory withDirectoryEnabled(boolean directoryEnabled) { + Utils.checkNotNull(directoryEnabled, "directoryEnabled"); + this.directoryEnabled = directoryEnabled; + return this; + } + + /** + * The user's external ID as reported by the directory, if any. + */ + public UserDirectory withExternalId(String externalId) { + Utils.checkNotNull(externalId, "externalId"); + this.externalId = Optional.ofNullable(externalId); + return this; + } + + + /** + * The user's external ID as reported by the directory, if any. + */ + public UserDirectory withExternalId(Optional externalId) { + Utils.checkNotNull(externalId, "externalId"); + this.externalId = externalId; + return this; + } + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + UserDirectory other = (UserDirectory) o; + return + Utils.enhancedDeepEquals(this.id, other.id) && + Utils.enhancedDeepEquals(this.directoryName, other.directoryName) && + Utils.enhancedDeepEquals(this.provider, other.provider) && + Utils.enhancedDeepEquals(this.enterpriseConnectionId, other.enterpriseConnectionId) && + Utils.enhancedDeepEquals(this.groups, other.groups) && + Utils.enhancedDeepEquals(this.directoryId, other.directoryId) && + Utils.enhancedDeepEquals(this.directoryEnabled, other.directoryEnabled) && + Utils.enhancedDeepEquals(this.externalId, other.externalId); + } + + @Override + public int hashCode() { + return Utils.enhancedHash( + id, directoryName, provider, + enterpriseConnectionId, groups, directoryId, + directoryEnabled, externalId); + } + + @Override + public String toString() { + return Utils.toString(UserDirectory.class, + "id", id, + "directoryName", directoryName, + "provider", provider, + "enterpriseConnectionId", enterpriseConnectionId, + "groups", groups, + "directoryId", directoryId, + "directoryEnabled", directoryEnabled, + "externalId", externalId); + } + + @SuppressWarnings("UnusedReturnValue") + public final static class Builder { + + private String id; + + private String directoryName; + + private String provider; + + private Optional enterpriseConnectionId = Optional.empty(); + + private Optional> groups = Optional.empty(); + + private String directoryId; + + private Boolean directoryEnabled; + + private Optional externalId = Optional.empty(); + + private Builder() { + // force use of static builder() method + } + + + /** + * The user's resource ID in this directory. + */ + public Builder id(String id) { + Utils.checkNotNull(id, "id"); + this.id = id; + return this; + } + + + public Builder directoryName(String directoryName) { + Utils.checkNotNull(directoryName, "directoryName"); + this.directoryName = directoryName; + return this; + } + + + public Builder provider(String provider) { + Utils.checkNotNull(provider, "provider"); + this.provider = provider; + return this; + } + + + public Builder enterpriseConnectionId(String enterpriseConnectionId) { + Utils.checkNotNull(enterpriseConnectionId, "enterpriseConnectionId"); + this.enterpriseConnectionId = Optional.ofNullable(enterpriseConnectionId); + return this; + } + + public Builder enterpriseConnectionId(Optional enterpriseConnectionId) { + Utils.checkNotNull(enterpriseConnectionId, "enterpriseConnectionId"); + this.enterpriseConnectionId = enterpriseConnectionId; + return this; + } + + + /** + * Omitted when groups were not loaded; an empty array means no group memberships. + */ + public Builder groups(List groups) { + Utils.checkNotNull(groups, "groups"); + this.groups = Optional.ofNullable(groups); + return this; + } + + /** + * Omitted when groups were not loaded; an empty array means no group memberships. + */ + public Builder groups(Optional> groups) { + Utils.checkNotNull(groups, "groups"); + this.groups = groups; + return this; + } + + + /** + * The ID of the directory the user is provisioned from. + */ + public Builder directoryId(String directoryId) { + Utils.checkNotNull(directoryId, "directoryId"); + this.directoryId = directoryId; + return this; + } + + + /** + * Whether the directory is currently enabled. + */ + public Builder directoryEnabled(boolean directoryEnabled) { + Utils.checkNotNull(directoryEnabled, "directoryEnabled"); + this.directoryEnabled = directoryEnabled; + return this; + } + + + /** + * The user's external ID as reported by the directory, if any. + */ + public Builder externalId(String externalId) { + Utils.checkNotNull(externalId, "externalId"); + this.externalId = Optional.ofNullable(externalId); + return this; + } + + /** + * The user's external ID as reported by the directory, if any. + */ + public Builder externalId(Optional externalId) { + Utils.checkNotNull(externalId, "externalId"); + this.externalId = externalId; + return this; + } + + public UserDirectory build() { + + return new UserDirectory( + id, directoryName, provider, + enterpriseConnectionId, groups, directoryId, + directoryEnabled, externalId); + } + + } +} diff --git a/src/main/java/com/clerk/backend_api/models/components/UserGroups.java b/src/main/java/com/clerk/backend_api/models/components/UserGroups.java new file mode 100644 index 00000000..8eac8c4e --- /dev/null +++ b/src/main/java/com/clerk/backend_api/models/components/UserGroups.java @@ -0,0 +1,119 @@ +/* + * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + */ +package com.clerk.backend_api.models.components; + +import com.clerk.backend_api.utils.Utils; +import com.fasterxml.jackson.annotation.JsonCreator; +import com.fasterxml.jackson.annotation.JsonIgnore; +import com.fasterxml.jackson.annotation.JsonProperty; +import java.lang.Override; +import java.lang.String; + + +public class UserGroups { + + @JsonProperty("id") + private String id; + + + @JsonProperty("display_name") + private String displayName; + + @JsonCreator + public UserGroups( + @JsonProperty("id") String id, + @JsonProperty("display_name") String displayName) { + Utils.checkNotNull(id, "id"); + Utils.checkNotNull(displayName, "displayName"); + this.id = id; + this.displayName = displayName; + } + + @JsonIgnore + public String id() { + return id; + } + + @JsonIgnore + public String displayName() { + return displayName; + } + + public static Builder builder() { + return new Builder(); + } + + + public UserGroups withId(String id) { + Utils.checkNotNull(id, "id"); + this.id = id; + return this; + } + + public UserGroups withDisplayName(String displayName) { + Utils.checkNotNull(displayName, "displayName"); + this.displayName = displayName; + return this; + } + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + UserGroups other = (UserGroups) o; + return + Utils.enhancedDeepEquals(this.id, other.id) && + Utils.enhancedDeepEquals(this.displayName, other.displayName); + } + + @Override + public int hashCode() { + return Utils.enhancedHash( + id, displayName); + } + + @Override + public String toString() { + return Utils.toString(UserGroups.class, + "id", id, + "displayName", displayName); + } + + @SuppressWarnings("UnusedReturnValue") + public final static class Builder { + + private String id; + + private String displayName; + + private Builder() { + // force use of static builder() method + } + + + public Builder id(String id) { + Utils.checkNotNull(id, "id"); + this.id = id; + return this; + } + + + public Builder displayName(String displayName) { + Utils.checkNotNull(displayName, "displayName"); + this.displayName = displayName; + return this; + } + + public UserGroups build() { + + return new UserGroups( + id, displayName); + } + + } +} diff --git a/src/main/java/com/clerk/backend_api/models/components/UserScimGroups.java b/src/main/java/com/clerk/backend_api/models/components/UserScimGroups.java new file mode 100644 index 00000000..a5c43482 --- /dev/null +++ b/src/main/java/com/clerk/backend_api/models/components/UserScimGroups.java @@ -0,0 +1,119 @@ +/* + * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + */ +package com.clerk.backend_api.models.components; + +import com.clerk.backend_api.utils.Utils; +import com.fasterxml.jackson.annotation.JsonCreator; +import com.fasterxml.jackson.annotation.JsonIgnore; +import com.fasterxml.jackson.annotation.JsonProperty; +import java.lang.Override; +import java.lang.String; + + +public class UserScimGroups { + + @JsonProperty("id") + private String id; + + + @JsonProperty("display_name") + private String displayName; + + @JsonCreator + public UserScimGroups( + @JsonProperty("id") String id, + @JsonProperty("display_name") String displayName) { + Utils.checkNotNull(id, "id"); + Utils.checkNotNull(displayName, "displayName"); + this.id = id; + this.displayName = displayName; + } + + @JsonIgnore + public String id() { + return id; + } + + @JsonIgnore + public String displayName() { + return displayName; + } + + public static Builder builder() { + return new Builder(); + } + + + public UserScimGroups withId(String id) { + Utils.checkNotNull(id, "id"); + this.id = id; + return this; + } + + public UserScimGroups withDisplayName(String displayName) { + Utils.checkNotNull(displayName, "displayName"); + this.displayName = displayName; + return this; + } + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + UserScimGroups other = (UserScimGroups) o; + return + Utils.enhancedDeepEquals(this.id, other.id) && + Utils.enhancedDeepEquals(this.displayName, other.displayName); + } + + @Override + public int hashCode() { + return Utils.enhancedHash( + id, displayName); + } + + @Override + public String toString() { + return Utils.toString(UserScimGroups.class, + "id", id, + "displayName", displayName); + } + + @SuppressWarnings("UnusedReturnValue") + public final static class Builder { + + private String id; + + private String displayName; + + private Builder() { + // force use of static builder() method + } + + + public Builder id(String id) { + Utils.checkNotNull(id, "id"); + this.id = id; + return this; + } + + + public Builder displayName(String displayName) { + Utils.checkNotNull(displayName, "displayName"); + this.displayName = displayName; + return this; + } + + public UserScimGroups build() { + + return new UserScimGroups( + id, displayName); + } + + } +} diff --git a/src/main/java/com/clerk/backend_api/models/operations/AddDomainRequestBody.java b/src/main/java/com/clerk/backend_api/models/operations/AddDomainRequestBody.java index 62dcef05..915ca0f0 100644 --- a/src/main/java/com/clerk/backend_api/models/operations/AddDomainRequestBody.java +++ b/src/main/java/com/clerk/backend_api/models/operations/AddDomainRequestBody.java @@ -3,14 +3,12 @@ */ package com.clerk.backend_api.models.operations; -import com.clerk.backend_api.utils.LazySingletonValue; import com.clerk.backend_api.utils.Utils; import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonInclude.Include; import com.fasterxml.jackson.annotation.JsonInclude; import com.fasterxml.jackson.annotation.JsonProperty; -import com.fasterxml.jackson.core.type.TypeReference; import java.lang.Boolean; import java.lang.Override; import java.lang.String; @@ -25,7 +23,8 @@ public class AddDomainRequestBody { private String name; /** - * Marks the new domain as satellite. Only `true` is accepted at the moment. + * Marks the new domain as satellite. Set to `false` only when migrating a production instance from an + * active provider domain to a custom domain. */ @JsonProperty("is_satellite") private boolean isSatellite; @@ -41,17 +40,20 @@ public class AddDomainRequestBody { @JsonCreator public AddDomainRequestBody( @JsonProperty("name") String name, + @JsonProperty("is_satellite") boolean isSatellite, @JsonProperty("proxy_url") JsonNullable proxyUrl) { Utils.checkNotNull(name, "name"); + Utils.checkNotNull(isSatellite, "isSatellite"); Utils.checkNotNull(proxyUrl, "proxyUrl"); this.name = name; - this.isSatellite = Builder._SINGLETON_VALUE_IsSatellite.value(); + this.isSatellite = isSatellite; this.proxyUrl = proxyUrl; } public AddDomainRequestBody( - String name) { - this(name, JsonNullable.undefined()); + String name, + boolean isSatellite) { + this(name, isSatellite, JsonNullable.undefined()); } /** @@ -63,7 +65,8 @@ public String name() { } /** - * Marks the new domain as satellite. Only `true` is accepted at the moment. + * Marks the new domain as satellite. Set to `false` only when migrating a production instance from an + * active provider domain to a custom domain. */ @JsonIgnore public boolean isSatellite() { @@ -93,6 +96,16 @@ public AddDomainRequestBody withName(String name) { return this; } + /** + * Marks the new domain as satellite. Set to `false` only when migrating a production instance from an + * active provider domain to a custom domain. + */ + public AddDomainRequestBody withIsSatellite(boolean isSatellite) { + Utils.checkNotNull(isSatellite, "isSatellite"); + this.isSatellite = isSatellite; + return this; + } + /** * The full URL of the proxy which will forward requests to the Clerk Frontend API for this domain. * Applicable only to production instances. @@ -147,6 +160,8 @@ public final static class Builder { private String name; + private Boolean isSatellite; + private JsonNullable proxyUrl = JsonNullable.undefined(); private Builder() { @@ -164,6 +179,17 @@ public Builder name(String name) { } + /** + * Marks the new domain as satellite. Set to `false` only when migrating a production instance from an + * active provider domain to a custom domain. + */ + public Builder isSatellite(boolean isSatellite) { + Utils.checkNotNull(isSatellite, "isSatellite"); + this.isSatellite = isSatellite; + return this; + } + + /** * The full URL of the proxy which will forward requests to the Clerk Frontend API for this domain. * Applicable only to production instances. @@ -187,14 +213,8 @@ public Builder proxyUrl(JsonNullable proxyUrl) { public AddDomainRequestBody build() { return new AddDomainRequestBody( - name, proxyUrl); + name, isSatellite, proxyUrl); } - - private static final LazySingletonValue _SINGLETON_VALUE_IsSatellite = - new LazySingletonValue<>( - "is_satellite", - "true", - new TypeReference() {}); } } diff --git a/src/main/java/com/clerk/backend_api/models/operations/CreateOAuthApplicationRequestBody.java b/src/main/java/com/clerk/backend_api/models/operations/CreateOAuthApplicationRequestBody.java index 52aee8a2..f3995715 100644 --- a/src/main/java/com/clerk/backend_api/models/operations/CreateOAuthApplicationRequestBody.java +++ b/src/main/java/com/clerk/backend_api/models/operations/CreateOAuthApplicationRequestBody.java @@ -68,8 +68,8 @@ public class CreateOAuthApplicationRequestBody { private JsonNullable pkceRequired; /** - * True to enable the OAuth Device Authorization Grant for this application. Enabling requires the - * OAuth Device Authorization Grant feature to be enabled for the instance. + * True to enable the OAuth Device Authorization Grant for this application. Enabling requires the new + * OAuth IdP and a reachable device verification page. */ @JsonInclude(Include.NON_ABSENT) @JsonProperty("device_authorization_grant_enabled") @@ -172,8 +172,8 @@ public JsonNullable pkceRequired() { } /** - * True to enable the OAuth Device Authorization Grant for this application. Enabling requires the - * OAuth Device Authorization Grant feature to be enabled for the instance. + * True to enable the OAuth Device Authorization Grant for this application. Enabling requires the new + * OAuth IdP and a reachable device verification page. */ @JsonIgnore public JsonNullable deviceAuthorizationGrantEnabled() { @@ -302,8 +302,8 @@ public CreateOAuthApplicationRequestBody withPkceRequired(JsonNullable } /** - * True to enable the OAuth Device Authorization Grant for this application. Enabling requires the - * OAuth Device Authorization Grant feature to be enabled for the instance. + * True to enable the OAuth Device Authorization Grant for this application. Enabling requires the new + * OAuth IdP and a reachable device verification page. */ public CreateOAuthApplicationRequestBody withDeviceAuthorizationGrantEnabled(boolean deviceAuthorizationGrantEnabled) { Utils.checkNotNull(deviceAuthorizationGrantEnabled, "deviceAuthorizationGrantEnabled"); @@ -312,8 +312,8 @@ public CreateOAuthApplicationRequestBody withDeviceAuthorizationGrantEnabled(boo } /** - * True to enable the OAuth Device Authorization Grant for this application. Enabling requires the - * OAuth Device Authorization Grant feature to be enabled for the instance. + * True to enable the OAuth Device Authorization Grant for this application. Enabling requires the new + * OAuth IdP and a reachable device verification page. */ public CreateOAuthApplicationRequestBody withDeviceAuthorizationGrantEnabled(JsonNullable deviceAuthorizationGrantEnabled) { Utils.checkNotNull(deviceAuthorizationGrantEnabled, "deviceAuthorizationGrantEnabled"); @@ -520,8 +520,8 @@ public Builder pkceRequired(JsonNullable pkceRequired) { /** - * True to enable the OAuth Device Authorization Grant for this application. Enabling requires the - * OAuth Device Authorization Grant feature to be enabled for the instance. + * True to enable the OAuth Device Authorization Grant for this application. Enabling requires the new + * OAuth IdP and a reachable device verification page. */ public Builder deviceAuthorizationGrantEnabled(boolean deviceAuthorizationGrantEnabled) { Utils.checkNotNull(deviceAuthorizationGrantEnabled, "deviceAuthorizationGrantEnabled"); @@ -530,8 +530,8 @@ public Builder deviceAuthorizationGrantEnabled(boolean deviceAuthorizationGrantE } /** - * True to enable the OAuth Device Authorization Grant for this application. Enabling requires the - * OAuth Device Authorization Grant feature to be enabled for the instance. + * True to enable the OAuth Device Authorization Grant for this application. Enabling requires the new + * OAuth IdP and a reachable device verification page. */ public Builder deviceAuthorizationGrantEnabled(JsonNullable deviceAuthorizationGrantEnabled) { Utils.checkNotNull(deviceAuthorizationGrantEnabled, "deviceAuthorizationGrantEnabled"); diff --git a/src/main/java/com/clerk/backend_api/models/operations/DeleteDomainRequest.java b/src/main/java/com/clerk/backend_api/models/operations/DeleteDomainRequest.java index 5ac22d07..7d67315e 100644 --- a/src/main/java/com/clerk/backend_api/models/operations/DeleteDomainRequest.java +++ b/src/main/java/com/clerk/backend_api/models/operations/DeleteDomainRequest.java @@ -13,7 +13,7 @@ public class DeleteDomainRequest { /** - * The ID of the domain that will be deleted. Must be a satellite domain. + * The ID of the domain that will be deleted. */ @SpeakeasyMetadata("pathParam:style=simple,explode=false,name=domain_id") private String domainId; @@ -26,7 +26,7 @@ public DeleteDomainRequest( } /** - * The ID of the domain that will be deleted. Must be a satellite domain. + * The ID of the domain that will be deleted. */ @JsonIgnore public String domainId() { @@ -39,7 +39,7 @@ public static Builder builder() { /** - * The ID of the domain that will be deleted. Must be a satellite domain. + * The ID of the domain that will be deleted. */ public DeleteDomainRequest withDomainId(String domainId) { Utils.checkNotNull(domainId, "domainId"); @@ -83,7 +83,7 @@ private Builder() { /** - * The ID of the domain that will be deleted. Must be a satellite domain. + * The ID of the domain that will be deleted. */ public Builder domainId(String domainId) { Utils.checkNotNull(domainId, "domainId"); diff --git a/src/main/java/com/clerk/backend_api/models/operations/GetReverificationRequest.java b/src/main/java/com/clerk/backend_api/models/operations/GetReverificationRequest.java new file mode 100644 index 00000000..83baa25e --- /dev/null +++ b/src/main/java/com/clerk/backend_api/models/operations/GetReverificationRequest.java @@ -0,0 +1,141 @@ +/* + * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + */ +package com.clerk.backend_api.models.operations; + +import com.clerk.backend_api.utils.SpeakeasyMetadata; +import com.clerk.backend_api.utils.Utils; +import com.fasterxml.jackson.annotation.JsonCreator; +import com.fasterxml.jackson.annotation.JsonIgnore; +import java.lang.Override; +import java.lang.String; + + +public class GetReverificationRequest { + /** + * The ID of the session the reverification belongs to + */ + @SpeakeasyMetadata("pathParam:style=simple,explode=false,name=session_id") + private String sessionId; + + /** + * The ID of the reverification + */ + @SpeakeasyMetadata("pathParam:style=simple,explode=false,name=reverification_id") + private String reverificationId; + + @JsonCreator + public GetReverificationRequest( + String sessionId, + String reverificationId) { + Utils.checkNotNull(sessionId, "sessionId"); + Utils.checkNotNull(reverificationId, "reverificationId"); + this.sessionId = sessionId; + this.reverificationId = reverificationId; + } + + /** + * The ID of the session the reverification belongs to + */ + @JsonIgnore + public String sessionId() { + return sessionId; + } + + /** + * The ID of the reverification + */ + @JsonIgnore + public String reverificationId() { + return reverificationId; + } + + public static Builder builder() { + return new Builder(); + } + + + /** + * The ID of the session the reverification belongs to + */ + public GetReverificationRequest withSessionId(String sessionId) { + Utils.checkNotNull(sessionId, "sessionId"); + this.sessionId = sessionId; + return this; + } + + /** + * The ID of the reverification + */ + public GetReverificationRequest withReverificationId(String reverificationId) { + Utils.checkNotNull(reverificationId, "reverificationId"); + this.reverificationId = reverificationId; + return this; + } + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + GetReverificationRequest other = (GetReverificationRequest) o; + return + Utils.enhancedDeepEquals(this.sessionId, other.sessionId) && + Utils.enhancedDeepEquals(this.reverificationId, other.reverificationId); + } + + @Override + public int hashCode() { + return Utils.enhancedHash( + sessionId, reverificationId); + } + + @Override + public String toString() { + return Utils.toString(GetReverificationRequest.class, + "sessionId", sessionId, + "reverificationId", reverificationId); + } + + @SuppressWarnings("UnusedReturnValue") + public final static class Builder { + + private String sessionId; + + private String reverificationId; + + private Builder() { + // force use of static builder() method + } + + + /** + * The ID of the session the reverification belongs to + */ + public Builder sessionId(String sessionId) { + Utils.checkNotNull(sessionId, "sessionId"); + this.sessionId = sessionId; + return this; + } + + + /** + * The ID of the reverification + */ + public Builder reverificationId(String reverificationId) { + Utils.checkNotNull(reverificationId, "reverificationId"); + this.reverificationId = reverificationId; + return this; + } + + public GetReverificationRequest build() { + + return new GetReverificationRequest( + sessionId, reverificationId); + } + + } +} diff --git a/src/main/java/com/clerk/backend_api/models/operations/GetReverificationRequestBuilder.java b/src/main/java/com/clerk/backend_api/models/operations/GetReverificationRequestBuilder.java new file mode 100644 index 00000000..851b07bb --- /dev/null +++ b/src/main/java/com/clerk/backend_api/models/operations/GetReverificationRequestBuilder.java @@ -0,0 +1,73 @@ +/* + * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + */ +package com.clerk.backend_api.models.operations; + +import static com.clerk.backend_api.operations.Operations.RequestOperation; + +import com.clerk.backend_api.SDKConfiguration; +import com.clerk.backend_api.operations.GetReverification; +import com.clerk.backend_api.utils.Headers; +import com.clerk.backend_api.utils.Options; +import com.clerk.backend_api.utils.RetryConfig; +import com.clerk.backend_api.utils.Utils; +import java.lang.String; +import java.util.Optional; + +public class GetReverificationRequestBuilder { + + private String sessionId; + private String reverificationId; + private Optional retryConfig = Optional.empty(); + private final SDKConfiguration sdkConfiguration; + private final Headers _headers = new Headers(); + + public GetReverificationRequestBuilder(SDKConfiguration sdkConfiguration) { + this.sdkConfiguration = sdkConfiguration; + } + + public GetReverificationRequestBuilder sessionId(String sessionId) { + Utils.checkNotNull(sessionId, "sessionId"); + this.sessionId = sessionId; + return this; + } + + public GetReverificationRequestBuilder reverificationId(String reverificationId) { + Utils.checkNotNull(reverificationId, "reverificationId"); + this.reverificationId = reverificationId; + return this; + } + + public GetReverificationRequestBuilder retryConfig(RetryConfig retryConfig) { + Utils.checkNotNull(retryConfig, "retryConfig"); + this.retryConfig = Optional.of(retryConfig); + return this; + } + + public GetReverificationRequestBuilder retryConfig(Optional retryConfig) { + Utils.checkNotNull(retryConfig, "retryConfig"); + this.retryConfig = retryConfig; + return this; + } + + + private GetReverificationRequest buildRequest() { + + GetReverificationRequest request = new GetReverificationRequest(sessionId, + reverificationId); + + return request; + } + + public GetReverificationResponse call() { + Optional options = Optional.of(Options.builder() + .retryConfig(retryConfig) + .build()); + + RequestOperation operation + = new GetReverification.Sync(sdkConfiguration, options, _headers); + GetReverificationRequest request = buildRequest(); + + return operation.handleResponse(operation.doRequest(request)); + } +} diff --git a/src/main/java/com/clerk/backend_api/models/operations/GetReverificationResponse.java b/src/main/java/com/clerk/backend_api/models/operations/GetReverificationResponse.java new file mode 100644 index 00000000..a4701c55 --- /dev/null +++ b/src/main/java/com/clerk/backend_api/models/operations/GetReverificationResponse.java @@ -0,0 +1,253 @@ +/* + * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + */ +package com.clerk.backend_api.models.operations; + +import com.clerk.backend_api.models.components.Reverification; +import com.clerk.backend_api.utils.Response; +import com.clerk.backend_api.utils.Utils; +import com.fasterxml.jackson.annotation.JsonCreator; +import com.fasterxml.jackson.annotation.JsonIgnore; +import java.io.InputStream; +import java.lang.Integer; +import java.lang.Override; +import java.lang.String; +import java.lang.SuppressWarnings; +import java.net.http.HttpResponse; +import java.util.Optional; + + +public class GetReverificationResponse implements Response { + /** + * HTTP response content type for this operation + */ + private String contentType; + + /** + * HTTP response status code for this operation + */ + private int statusCode; + + /** + * Raw HTTP response; suitable for custom response parsing + */ + private HttpResponse rawResponse; + + /** + * Success + */ + private Optional reverification; + + @JsonCreator + public GetReverificationResponse( + String contentType, + int statusCode, + HttpResponse rawResponse, + Optional reverification) { + Utils.checkNotNull(contentType, "contentType"); + Utils.checkNotNull(statusCode, "statusCode"); + Utils.checkNotNull(rawResponse, "rawResponse"); + Utils.checkNotNull(reverification, "reverification"); + this.contentType = contentType; + this.statusCode = statusCode; + this.rawResponse = rawResponse; + this.reverification = reverification; + } + + public GetReverificationResponse( + String contentType, + int statusCode, + HttpResponse rawResponse) { + this(contentType, statusCode, rawResponse, + Optional.empty()); + } + + /** + * HTTP response content type for this operation + */ + @JsonIgnore + public String contentType() { + return contentType; + } + + /** + * HTTP response status code for this operation + */ + @JsonIgnore + public int statusCode() { + return statusCode; + } + + /** + * Raw HTTP response; suitable for custom response parsing + */ + @JsonIgnore + public HttpResponse rawResponse() { + return rawResponse; + } + + /** + * Success + */ + @SuppressWarnings("unchecked") + @JsonIgnore + public Optional reverification() { + return (Optional) reverification; + } + + public static Builder builder() { + return new Builder(); + } + + + /** + * HTTP response content type for this operation + */ + public GetReverificationResponse withContentType(String contentType) { + Utils.checkNotNull(contentType, "contentType"); + this.contentType = contentType; + return this; + } + + /** + * HTTP response status code for this operation + */ + public GetReverificationResponse withStatusCode(int statusCode) { + Utils.checkNotNull(statusCode, "statusCode"); + this.statusCode = statusCode; + return this; + } + + /** + * Raw HTTP response; suitable for custom response parsing + */ + public GetReverificationResponse withRawResponse(HttpResponse rawResponse) { + Utils.checkNotNull(rawResponse, "rawResponse"); + this.rawResponse = rawResponse; + return this; + } + + /** + * Success + */ + public GetReverificationResponse withReverification(Reverification reverification) { + Utils.checkNotNull(reverification, "reverification"); + this.reverification = Optional.ofNullable(reverification); + return this; + } + + + /** + * Success + */ + public GetReverificationResponse withReverification(Optional reverification) { + Utils.checkNotNull(reverification, "reverification"); + this.reverification = reverification; + return this; + } + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + GetReverificationResponse other = (GetReverificationResponse) o; + return + Utils.enhancedDeepEquals(this.contentType, other.contentType) && + Utils.enhancedDeepEquals(this.statusCode, other.statusCode) && + Utils.enhancedDeepEquals(this.rawResponse, other.rawResponse) && + Utils.enhancedDeepEquals(this.reverification, other.reverification); + } + + @Override + public int hashCode() { + return Utils.enhancedHash( + contentType, statusCode, rawResponse, + reverification); + } + + @Override + public String toString() { + return Utils.toString(GetReverificationResponse.class, + "contentType", contentType, + "statusCode", statusCode, + "rawResponse", rawResponse, + "reverification", reverification); + } + + @SuppressWarnings("UnusedReturnValue") + public final static class Builder { + + private String contentType; + + private Integer statusCode; + + private HttpResponse rawResponse; + + private Optional reverification = Optional.empty(); + + private Builder() { + // force use of static builder() method + } + + + /** + * HTTP response content type for this operation + */ + public Builder contentType(String contentType) { + Utils.checkNotNull(contentType, "contentType"); + this.contentType = contentType; + return this; + } + + + /** + * HTTP response status code for this operation + */ + public Builder statusCode(int statusCode) { + Utils.checkNotNull(statusCode, "statusCode"); + this.statusCode = statusCode; + return this; + } + + + /** + * Raw HTTP response; suitable for custom response parsing + */ + public Builder rawResponse(HttpResponse rawResponse) { + Utils.checkNotNull(rawResponse, "rawResponse"); + this.rawResponse = rawResponse; + return this; + } + + + /** + * Success + */ + public Builder reverification(Reverification reverification) { + Utils.checkNotNull(reverification, "reverification"); + this.reverification = Optional.ofNullable(reverification); + return this; + } + + /** + * Success + */ + public Builder reverification(Optional reverification) { + Utils.checkNotNull(reverification, "reverification"); + this.reverification = reverification; + return this; + } + + public GetReverificationResponse build() { + + return new GetReverificationResponse( + contentType, statusCode, rawResponse, + reverification); + } + + } +} diff --git a/src/main/java/com/clerk/backend_api/models/operations/ResponseBody1.java b/src/main/java/com/clerk/backend_api/models/operations/ResponseBody1.java index d4b02e68..59c76c23 100644 --- a/src/main/java/com/clerk/backend_api/models/operations/ResponseBody1.java +++ b/src/main/java/com/clerk/backend_api/models/operations/ResponseBody1.java @@ -13,6 +13,7 @@ import java.lang.Double; import java.lang.Override; import java.lang.String; +import java.lang.SuppressWarnings; import java.util.List; import java.util.Optional; @@ -38,6 +39,13 @@ public class ResponseBody1 { @JsonProperty("scopes") private List scopes; + /** + * The audiences of the access token. Omitted when no audience is set. + */ + @JsonInclude(Include.NON_ABSENT) + @JsonProperty("aud") + private Optional> aud; + @JsonProperty("revoked") private boolean revoked; @@ -71,6 +79,7 @@ public ResponseBody1( @JsonProperty("client_id") String clientId, @JsonProperty("subject") String subject, @JsonProperty("scopes") List scopes, + @JsonProperty("aud") Optional> aud, @JsonProperty("revoked") boolean revoked, @JsonProperty("revocation_reason") Optional revocationReason, @JsonProperty("expired") boolean expired, @@ -82,6 +91,7 @@ public ResponseBody1( Utils.checkNotNull(clientId, "clientId"); Utils.checkNotNull(subject, "subject"); Utils.checkNotNull(scopes, "scopes"); + Utils.checkNotNull(aud, "aud"); Utils.checkNotNull(revoked, "revoked"); Utils.checkNotNull(revocationReason, "revocationReason"); Utils.checkNotNull(expired, "expired"); @@ -93,6 +103,7 @@ public ResponseBody1( this.clientId = clientId; this.subject = subject; this.scopes = scopes; + this.aud = aud; this.revoked = revoked; this.revocationReason = revocationReason; this.expired = expired; @@ -112,9 +123,9 @@ public ResponseBody1( double createdAt, double updatedAt) { this(object, id, clientId, - subject, scopes, revoked, - Optional.empty(), expired, Optional.empty(), - createdAt, updatedAt); + subject, scopes, Optional.empty(), + revoked, Optional.empty(), expired, + Optional.empty(), createdAt, updatedAt); } @JsonIgnore @@ -142,6 +153,15 @@ public List scopes() { return scopes; } + /** + * The audiences of the access token. Omitted when no audience is set. + */ + @SuppressWarnings("unchecked") + @JsonIgnore + public Optional> aud() { + return (Optional>) aud; + } + @JsonIgnore public boolean revoked() { return revoked; @@ -207,6 +227,25 @@ public ResponseBody1 withScopes(List scopes) { return this; } + /** + * The audiences of the access token. Omitted when no audience is set. + */ + public ResponseBody1 withAud(List aud) { + Utils.checkNotNull(aud, "aud"); + this.aud = Optional.ofNullable(aud); + return this; + } + + + /** + * The audiences of the access token. Omitted when no audience is set. + */ + public ResponseBody1 withAud(Optional> aud) { + Utils.checkNotNull(aud, "aud"); + this.aud = aud; + return this; + } + public ResponseBody1 withRevoked(boolean revoked) { Utils.checkNotNull(revoked, "revoked"); this.revoked = revoked; @@ -272,6 +311,7 @@ public boolean equals(java.lang.Object o) { Utils.enhancedDeepEquals(this.clientId, other.clientId) && Utils.enhancedDeepEquals(this.subject, other.subject) && Utils.enhancedDeepEquals(this.scopes, other.scopes) && + Utils.enhancedDeepEquals(this.aud, other.aud) && Utils.enhancedDeepEquals(this.revoked, other.revoked) && Utils.enhancedDeepEquals(this.revocationReason, other.revocationReason) && Utils.enhancedDeepEquals(this.expired, other.expired) && @@ -284,9 +324,9 @@ public boolean equals(java.lang.Object o) { public int hashCode() { return Utils.enhancedHash( object, id, clientId, - subject, scopes, revoked, - revocationReason, expired, expiration, - createdAt, updatedAt); + subject, scopes, aud, + revoked, revocationReason, expired, + expiration, createdAt, updatedAt); } @Override @@ -297,6 +337,7 @@ public String toString() { "clientId", clientId, "subject", subject, "scopes", scopes, + "aud", aud, "revoked", revoked, "revocationReason", revocationReason, "expired", expired, @@ -318,6 +359,8 @@ public final static class Builder { private List scopes; + private Optional> aud = Optional.empty(); + private Boolean revoked; private Optional revocationReason = Optional.empty(); @@ -370,6 +413,25 @@ public Builder scopes(List scopes) { } + /** + * The audiences of the access token. Omitted when no audience is set. + */ + public Builder aud(List aud) { + Utils.checkNotNull(aud, "aud"); + this.aud = Optional.ofNullable(aud); + return this; + } + + /** + * The audiences of the access token. Omitted when no audience is set. + */ + public Builder aud(Optional> aud) { + Utils.checkNotNull(aud, "aud"); + this.aud = aud; + return this; + } + + public Builder revoked(boolean revoked) { Utils.checkNotNull(revoked, "revoked"); this.revoked = revoked; @@ -427,9 +489,9 @@ public ResponseBody1 build() { return new ResponseBody1( object, id, clientId, - subject, scopes, revoked, - revocationReason, expired, expiration, - createdAt, updatedAt); + subject, scopes, aud, + revoked, revocationReason, expired, + expiration, createdAt, updatedAt); } } diff --git a/src/main/java/com/clerk/backend_api/models/operations/UpdateOAuthApplicationRequestBody.java b/src/main/java/com/clerk/backend_api/models/operations/UpdateOAuthApplicationRequestBody.java index 0fbdfda1..3fabf50a 100644 --- a/src/main/java/com/clerk/backend_api/models/operations/UpdateOAuthApplicationRequestBody.java +++ b/src/main/java/com/clerk/backend_api/models/operations/UpdateOAuthApplicationRequestBody.java @@ -71,9 +71,8 @@ public class UpdateOAuthApplicationRequestBody { private JsonNullable pkceRequired; /** - * True to enable the OAuth Device Authorization Grant for this application. Enabling requires the - * OAuth Device Authorization Grant feature to be enabled for the instance. Omit this field to leave - * the setting unchanged. + * True to enable the OAuth Device Authorization Grant for this application. Enabling requires the new + * OAuth IdP and a reachable device verification page. Omit this field to leave the setting unchanged. */ @JsonInclude(Include.NON_ABSENT) @JsonProperty("device_authorization_grant_enabled") @@ -179,9 +178,8 @@ public JsonNullable pkceRequired() { } /** - * True to enable the OAuth Device Authorization Grant for this application. Enabling requires the - * OAuth Device Authorization Grant feature to be enabled for the instance. Omit this field to leave - * the setting unchanged. + * True to enable the OAuth Device Authorization Grant for this application. Enabling requires the new + * OAuth IdP and a reachable device verification page. Omit this field to leave the setting unchanged. */ @JsonIgnore public JsonNullable deviceAuthorizationGrantEnabled() { @@ -328,9 +326,8 @@ public UpdateOAuthApplicationRequestBody withPkceRequired(JsonNullable } /** - * True to enable the OAuth Device Authorization Grant for this application. Enabling requires the - * OAuth Device Authorization Grant feature to be enabled for the instance. Omit this field to leave - * the setting unchanged. + * True to enable the OAuth Device Authorization Grant for this application. Enabling requires the new + * OAuth IdP and a reachable device verification page. Omit this field to leave the setting unchanged. */ public UpdateOAuthApplicationRequestBody withDeviceAuthorizationGrantEnabled(boolean deviceAuthorizationGrantEnabled) { Utils.checkNotNull(deviceAuthorizationGrantEnabled, "deviceAuthorizationGrantEnabled"); @@ -339,9 +336,8 @@ public UpdateOAuthApplicationRequestBody withDeviceAuthorizationGrantEnabled(boo } /** - * True to enable the OAuth Device Authorization Grant for this application. Enabling requires the - * OAuth Device Authorization Grant feature to be enabled for the instance. Omit this field to leave - * the setting unchanged. + * True to enable the OAuth Device Authorization Grant for this application. Enabling requires the new + * OAuth IdP and a reachable device verification page. Omit this field to leave the setting unchanged. */ public UpdateOAuthApplicationRequestBody withDeviceAuthorizationGrantEnabled(JsonNullable deviceAuthorizationGrantEnabled) { Utils.checkNotNull(deviceAuthorizationGrantEnabled, "deviceAuthorizationGrantEnabled"); @@ -566,9 +562,8 @@ public Builder pkceRequired(JsonNullable pkceRequired) { /** - * True to enable the OAuth Device Authorization Grant for this application. Enabling requires the - * OAuth Device Authorization Grant feature to be enabled for the instance. Omit this field to leave - * the setting unchanged. + * True to enable the OAuth Device Authorization Grant for this application. Enabling requires the new + * OAuth IdP and a reachable device verification page. Omit this field to leave the setting unchanged. */ public Builder deviceAuthorizationGrantEnabled(boolean deviceAuthorizationGrantEnabled) { Utils.checkNotNull(deviceAuthorizationGrantEnabled, "deviceAuthorizationGrantEnabled"); @@ -577,9 +572,8 @@ public Builder deviceAuthorizationGrantEnabled(boolean deviceAuthorizationGrantE } /** - * True to enable the OAuth Device Authorization Grant for this application. Enabling requires the - * OAuth Device Authorization Grant feature to be enabled for the instance. Omit this field to leave - * the setting unchanged. + * True to enable the OAuth Device Authorization Grant for this application. Enabling requires the new + * OAuth IdP and a reachable device verification page. Omit this field to leave the setting unchanged. */ public Builder deviceAuthorizationGrantEnabled(JsonNullable deviceAuthorizationGrantEnabled) { Utils.checkNotNull(deviceAuthorizationGrantEnabled, "deviceAuthorizationGrantEnabled"); diff --git a/src/main/java/com/clerk/backend_api/operations/AttemptPhoneNumberVerification.java b/src/main/java/com/clerk/backend_api/operations/AttemptPhoneNumberVerification.java index de3b86f6..81c73574 100644 --- a/src/main/java/com/clerk/backend_api/operations/AttemptPhoneNumberVerification.java +++ b/src/main/java/com/clerk/backend_api/operations/AttemptPhoneNumberVerification.java @@ -209,7 +209,7 @@ public AttemptPhoneNumberVerificationResponse handleResponse(HttpResponse retryStatusCodes; + final RetryConfig retryConfig; + final HTTPClient client; + final Headers _headers; + + public Base( + SDKConfiguration sdkConfiguration, Optional options, + Headers _headers) { + this.sdkConfiguration = sdkConfiguration; + this._headers =_headers; + this.baseUrl = this.sdkConfiguration.serverUrl(); + this.securitySource = this.sdkConfiguration.securitySource(); + options + .ifPresent(o -> o.validate(List.of(Options.Option.RETRY_CONFIG))); + this.retryStatusCodes = List.of("5XX"); + this.retryConfig = options + .flatMap(Options::retryConfig) + .or(sdkConfiguration::retryConfig) + .orElse(RetryConfig.builder().backoff(BackoffStrategy.builder() + .initialInterval(500, TimeUnit.MILLISECONDS) + .maxInterval(60000, TimeUnit.MILLISECONDS) + .baseFactor((double) (1.5)) + .maxElapsedTime(3600000, TimeUnit.MILLISECONDS) + .retryConnectError(true) + .build()) + .build()); + this.client = this.sdkConfiguration.client(); + } + + Optional securitySource() { + return Optional.ofNullable(this.securitySource); + } + + BeforeRequestContextImpl createBeforeRequestContext() { + return new BeforeRequestContextImpl( + this.sdkConfiguration, + this.baseUrl, + "GetReverification", + java.util.Optional.empty(), + securitySource()); + } + + AfterSuccessContextImpl createAfterSuccessContext() { + return new AfterSuccessContextImpl( + this.sdkConfiguration, + this.baseUrl, + "GetReverification", + java.util.Optional.empty(), + securitySource()); + } + + AfterErrorContextImpl createAfterErrorContext() { + return new AfterErrorContextImpl( + this.sdkConfiguration, + this.baseUrl, + "GetReverification", + java.util.Optional.empty(), + securitySource()); + } + HttpRequest buildRequest(T request, Class klass) throws Exception { + String url = Utils.generateURL( + klass, + this.baseUrl, + "/sessions/{session_id}/reverifications/{reverification_id}", + request, null); + HTTPRequest req = new HTTPRequest(url, "GET"); + req.addHeader("Accept", "application/json") + .addHeader("user-agent", SDKConfiguration.USER_AGENT); + _headers.forEach((k, list) -> list.forEach(v -> req.addHeader(k, v))); + Utils.configureSecurity(req, this.sdkConfiguration.securitySource().getSecurity()); + + return req.build(); + } + } + + public static class Sync extends Base + implements RequestOperation { + public Sync( + SDKConfiguration sdkConfiguration, Optional options, + Headers _headers) { + super( + sdkConfiguration, options, + _headers); + } + + private HttpRequest onBuildRequest(GetReverificationRequest request) throws Exception { + HttpRequest req = buildRequest(request, GetReverificationRequest.class); + return sdkConfiguration.hooks().beforeRequest(createBeforeRequestContext(), req); + } + + private HttpResponse onError(HttpResponse response, Exception error) throws Exception { + return sdkConfiguration.hooks().afterError( + createAfterErrorContext(), + Optional.ofNullable(response), + Optional.ofNullable(error)); + } + + private HttpResponse onSuccess(HttpResponse response) throws Exception { + return sdkConfiguration.hooks().afterSuccess(createAfterSuccessContext(), response); + } + + @Override + public HttpResponse doRequest(GetReverificationRequest request) { + Retries retries = Retries.builder() + .action(() -> { + HttpRequest r; + try { + r = onBuildRequest(request); + } catch (Exception e) { + throw new NonRetryableException(e); + } + try { + HttpResponse httpRes = client.send(r); + if (Utils.statusCodeMatches(httpRes.statusCode(), "4XX", "5XX")) { + return onError(httpRes, null); + } + return httpRes; + } catch (Exception e) { + return onError(null, e); + } + }) + .retryConfig(retryConfig) + .statusCodes(retryStatusCodes) + .build(); + return unchecked(() -> onSuccess(retries.run())).get(); + } + + + @Override + public GetReverificationResponse handleResponse(HttpResponse response) { + String contentType = response + .headers() + .firstValue("Content-Type") + .orElse("application/octet-stream"); + GetReverificationResponse.Builder resBuilder = + GetReverificationResponse + .builder() + .contentType(contentType) + .statusCode(response.statusCode()) + .rawResponse(response); + + GetReverificationResponse res = resBuilder.build(); + + if (Utils.statusCodeMatches(response.statusCode(), "200")) { + if (Utils.contentTypeMatches(contentType, "application/json")) { + return res.withReverification(Utils.unmarshal(response, new TypeReference() {})); + } else { + throw SDKError.from("Unexpected content-type received: " + contentType, response); + } + } + if (Utils.statusCodeMatches(response.statusCode(), "400", "401", "404")) { + if (Utils.contentTypeMatches(contentType, "application/json")) { + throw ClerkErrors.from(response); + } else { + throw SDKError.from("Unexpected content-type received: " + contentType, response); + } + } + if (Utils.statusCodeMatches(response.statusCode(), "4XX")) { + // no content + throw SDKError.from("API error occurred", response); + } + if (Utils.statusCodeMatches(response.statusCode(), "5XX")) { + // no content + throw SDKError.from("API error occurred", response); + } + throw SDKError.from("Unexpected status code received: " + response.statusCode(), response); + } + } +}