@@ -298,6 +298,7 @@ def delete_user(id:)
298298 # @param [String] client_id The WorkOS client ID for the environment
299299 # @param [String] ip_address The IP address of the request from the user who is attempting to authenticate.
300300 # @param [String] user_agent The user agent of the request from the user who is attempting to authenticate.
301+ # @param [String] invitation_token The token of an Invitation, if required.
301302 # @param [Hash] session An optional hash that determines whether the session should be sealed and
302303 # the optional cookie password.
303304 #
@@ -308,6 +309,7 @@ def authenticate_with_password(
308309 client_id :,
309310 ip_address : nil ,
310311 user_agent : nil ,
312+ invitation_token : nil ,
311313 session : nil
312314 )
313315 validate_session ( session )
@@ -322,6 +324,7 @@ def authenticate_with_password(
322324 password : password ,
323325 ip_address : ip_address ,
324326 user_agent : user_agent ,
327+ invitation_token : invitation_token ,
325328 grant_type : 'password' ,
326329 } ,
327330 ) ,
@@ -337,6 +340,7 @@ def authenticate_with_password(
337340 # @param [String] client_id The WorkOS client ID for the environment
338341 # @param [String] ip_address The IP address of the request from the user who is attempting to authenticate.
339342 # @param [String] user_agent The user agent of the request from the user who is attempting to authenticate.
343+ # @param [String] invitation_token The token of an Invitation, if required.
340344 # @param [Hash] session An optional hash that determines whether the session should be sealed and
341345 # the optional cookie password.
342346 #
@@ -346,6 +350,7 @@ def authenticate_with_code(
346350 client_id :,
347351 ip_address : nil ,
348352 user_agent : nil ,
353+ invitation_token : nil ,
349354 session : nil
350355 )
351356 validate_session ( session )
@@ -359,6 +364,7 @@ def authenticate_with_code(
359364 client_secret : WorkOS . config . key! ,
360365 ip_address : ip_address ,
361366 user_agent : user_agent ,
367+ invitation_token : invitation_token ,
362368 grant_type : 'authorization_code' ,
363369 } ,
364370 ) ,
@@ -415,6 +421,7 @@ def authenticate_with_refresh_token(
415421 # @param [String] link_authorization_code Used to link an OAuth profile to an existing user,
416422 # after having completed a Magic Code challenge.
417423 # @param [String] user_agent The user agent of the request from the user who is attempting to authenticate.
424+ # @param [String] invitation_token The token of an Invitation, if required.
418425 # @param [Hash] session An optional hash that determines whether the session should be sealed and
419426 # the optional cookie password.
420427 #
@@ -427,6 +434,7 @@ def authenticate_with_magic_auth(
427434 ip_address : nil ,
428435 user_agent : nil ,
429436 link_authorization_code : nil ,
437+ invitation_token : nil ,
430438 session : nil
431439 )
432440 validate_session ( session )
@@ -443,6 +451,7 @@ def authenticate_with_magic_auth(
443451 user_agent : user_agent ,
444452 grant_type : 'urn:workos:oauth:grant-type:magic-auth:code' ,
445453 link_authorization_code : link_authorization_code ,
454+ invitation_token : invitation_token ,
446455 } ,
447456 ) ,
448457 )
0 commit comments