8000 Create users, should set identity not id. · zhangjingcat/twilio-python@0c2323b · GitHub
[go: up one dir, main page]

Skip to content

Commit 0c2323b

Browse files
committed
Create users, should set identity not id.
1 parent 2e1bb16 commit 0c2323b

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

tests/ip_messaging/test_users.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ def test_create_user(self, mock):
2222
uri = "%s/Users" % (BASE_URI)
2323
list_resource.create('test_id')
2424
exp_params = {
25-
'Id': "test_id"
25+
'Identity': "test_id"
2626
}
2727

2828
mock.assert_called_with("POST", uri, data=exp_params, auth=AUTH,

twilio/rest/resources/ip_messaging/users.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -35,16 +35,16 @@ def list(self, **kwargs):
3535
"""
3636
return self.get_instances(kwargs)
3737

38-
def create(self, id, **kwargs):
38+
def create(self, identity, **kwargs):
3939
"""
4040
Creates a User
4141
42-
:param str id: The identity of the user.
42+
:param str identity: The identity of the user.
4343
:param str role_sid: The role to assign the user.
4444
4545
:return: A :class:`User` object
4646
"""
47-
kwargs["id"] = id
47+
kwargs["identity"] = identity
4848
return self.create_instance(kwargs)
4949

5050
def delete(self, sid):

0 commit comments

Comments
 (0)
0