-
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'main' of https://github.com/Jordan-Prescott/odins_spear
- Loading branch information
Showing
4 changed files
with
343 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
--- | ||
description: All things registration. | ||
--- | ||
|
||
# 🟢 Registration | ||
|
276 changes: 276 additions & 0 deletions
276
docs/methods/get/registration/bulk-user-registration.md
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,276 @@ | ||
--- | ||
description: my_api.get.bulk_user_regsitration() | ||
--- | ||
|
||
# 💚 Bulk User Registration | ||
|
||
Gets all users in a group and their device registrations. This includes soft phones. | ||
|
||
### Parameters  | ||
|
||
* service\_provider\_id (str): Service Provider/ Enterprise ID where Group is hosted.  | ||
* group\_id (str): Target Group ID where users are located. | ||
|
||
### Returns | ||
|
||
* dict: All users devices and details on device such as registration. | ||
|
||
### How To Use: | ||
|
||
{% code overflow="wrap" %} | ||
```python | ||
from odins_spear import api | ||
|
||
my_api= api.Api(base_url="https://base_url/api/vx", username="john.smith", password="ODIN_INSTANCE_1") | ||
my_api.authenticate() | ||
|
||
my_api.get.bulk_user_registration( | ||
"serviceProviderID", | ||
"groupID" | ||
) | ||
``` | ||
{% endcode %} | ||
|
||
### Example Returned Data of SIP Passwords (Formatted) | ||
|
||
```json | ||
{ | ||
"serviceProviderId": "LabEnterprise", | ||
"groupId": "regression.test", | ||
"users": [ | ||
{ | ||
"profile": { | ||
"userId": "[email protected]", | ||
"lastName": "User 1", | ||
"firstName": "Test", | ||
"department": "Bandwidth.com (regression.test)", | ||
"phoneNumber": "+1-2026951172", | ||
"phoneNumberActivated": true, | ||
"emailAddress": null, | ||
"hiraganaLastName": "User 1", | ||
"hiraganaFirstName": "Test", | ||
"inTrunkGroup": false, | ||
"extension": "2639", | ||
"countryCode": 1, | ||
"nationalPrefix": null, | ||
"domain": "alliedtelecom.net" | ||
}, | ||
"data": { | ||
"registrations": [ | ||
{ | ||
"deviceLevel": "Group", | ||
"deviceName": "ECG_0004f2accaf7", | ||
"order": 1, | ||
"uRI": "sip:[email protected]:5060;transport=udp;jtr=22-1808", | ||
"expiration": "Thu May 23 08:33:00 EDT 2019", | ||
"line/Port": "[email protected]", | ||
"endpointType": "Primary", | ||
"publicNetAddress": null, | ||
"publicPort": null, | ||
"privateNetAddress": null, | ||
"privatePort": null, | ||
"userAgent": "Polycom/5.4.1.14510 PolycomVVX-VVX_500-UA/5.4.1.14510", | ||
"lockoutStarted": null, | ||
"lockoutExpires": null, | ||
"lockoutCount": 0, | ||
"accessInfo": null | ||
} | ||
], | ||
"userId": "[email protected]" | ||
} | ||
}, | ||
{ | ||
"profile": { | ||
"userId": "[email protected]", | ||
"lastName": "User 3", | ||
"firstName": "Test", | ||
"department": "Level3 (regression.test)", | ||
"phoneNumber": "+1-3092650759", | ||
"phoneNumberActivated": true, | ||
"emailAddress": null, | ||
"hiraganaLastName": "User 3", | ||
"hiraganaFirstName": "Test", | ||
"inTrunkGroup": false, | ||
"extension": "2437", | ||
"countryCode": 1, | ||
"nationalPrefix": null, | ||
"domain": "alliedtelecom.net" | ||
}, | ||
"data": { | ||
"registrations": [ | ||
{ | ||
"deviceLevel": "Group", | ||
"deviceName": "ECG-0004F289F5AC", | ||
"order": 1, | ||
"uRI": "sip:[email protected]:5060;transport=udp;jtr=57-2417", | ||
"expiration": "Thu May 23 08:34:03 EDT 2019", | ||
"line/Port": "[email protected]", | ||
"endpointType": "Primary", | ||
"publicNetAddress": null, | ||
"publicPort": null, | ||
"privateNetAddress": null, | ||
"privatePort": null, | ||
"userAgent": "PolycomVVX-VVX_310-UA/5.6.2.1593", | ||
"lockoutStarted": null, | ||
"lockoutExpires": null, | ||
"lockoutCount": 0, | ||
"accessInfo": null | ||
} | ||
], | ||
"userId": "[email protected]" | ||
} | ||
}, | ||
{ | ||
"profile": { | ||
"userId": "[email protected]", | ||
"lastName": "Test", | ||
"firstName": "GS", | ||
"department": null, | ||
"phoneNumber": "", | ||
"phoneNumberActivated": null, | ||
"emailAddress": null, | ||
"hiraganaLastName": "Test", | ||
"hiraganaFirstName": "GS", | ||
"inTrunkGroup": false, | ||
"extension": "2456", | ||
"countryCode": null, | ||
"nationalPrefix": null, | ||
"domain": "alliedtelecom.net" | ||
}, | ||
"data": { | ||
"registrations": [], | ||
"userId": "[email protected]" | ||
} | ||
}, | ||
{ | ||
"profile": { | ||
"userId": "[email protected]", | ||
"lastName": "User 2", | ||
"firstName": "Test", | ||
"department": "Telnyx (regression.test)", | ||
"phoneNumber": "+1-2023478048", | ||
"phoneNumberActivated": true, | ||
"emailAddress": null, | ||
"hiraganaLastName": "User 2", | ||
"hiraganaFirstName": "Test", | ||
"inTrunkGroup": false, | ||
"extension": "6866", | ||
"countryCode": 1, | ||
"nationalPrefix": null, | ||
"domain": "alliedtelecom.net" | ||
}, | ||
"data": { | ||
"registrations": [ | ||
{ | ||
"deviceLevel": "Group", | ||
"deviceName": "ECG-0004f283b2f5", | ||
"order": 1, | ||
"uRI": "sip:[email protected]:5060;transport=udp;jtr=6-147", | ||
"expiration": "Thu May 23 08:30:12 EDT 2019", | ||
"line/Port": "[email protected]", | ||
"endpointType": "Primary", | ||
"publicNetAddress": null, | ||
"publicPort": null, | ||
"privateNetAddress": null, | ||
"privatePort": null, | ||
"userAgent": "Polycom/5.4.1.14510 PolycomVVX-VVX_500-UA/5.4.1.14510", | ||
"lockoutStarted": null, | ||
"lockoutExpires": null, | ||
"lockoutCount": 0, | ||
"accessInfo": null | ||
} | ||
], | ||
"userId": "[email protected]" | ||
} | ||
}, | ||
{ | ||
"profile": { | ||
"userId": "[email protected]", | ||
"lastName": "User", | ||
"firstName": "PB.Test", | ||
"department": null, | ||
"phoneNumber": "", | ||
"phoneNumberActivated": null, | ||
"emailAddress": null, | ||
"hiraganaLastName": "User", | ||
"hiraganaFirstName": "PB.Test", | ||
"inTrunkGroup": false, | ||
"extension": "", | ||
"countryCode": null, | ||
"nationalPrefix": null, | ||
"domain": "alliedtelecom.net" | ||
}, | ||
"data": { | ||
"registrations": [], | ||
"userId": "[email protected]" | ||
} | ||
}, | ||
{ | ||
"profile": { | ||
"userId": "[email protected]", | ||
"lastName": "XSP.Test", | ||
"firstName": "PB.User.XSP", | ||
"department": null, | ||
"phoneNumber": "", | ||
"phoneNumberActivated": null, | ||
"emailAddress": null, | ||
"hiraganaLastName": "XSP.Test", | ||
"hiraganaFirstName": "PB.User.XSP", | ||
"inTrunkGroup": false, | ||
"extension": "", | ||
"countryCode": null, | ||
"nationalPrefix": null, | ||
"domain": "alliedtelecom.net" | ||
}, | ||
"data": { | ||
"registrations": [], | ||
"userId": "[email protected]" | ||
} | ||
}, | ||
{ | ||
"profile": { | ||
"userId": "[email protected]", | ||
"lastName": "CLi.Test.User", | ||
"firstName": "CLi.Test.User", | ||
"department": null, | ||
"phoneNumber": "", | ||
"phoneNumberActivated": null, | ||
"emailAddress": null, | ||
"hiraganaLastName": "CLi.Test.User", | ||
"hiraganaFirstName": "CLi.Test.User", | ||
"inTrunkGroup": false, | ||
"extension": "", | ||
"countryCode": null, | ||
"nationalPrefix": null, | ||
"domain": "alliedtelecom.net" | ||
}, | ||
"data": { | ||
"registrations": [], | ||
"userId": "[email protected]" | ||
} | ||
}, | ||
{ | ||
"profile": { | ||
"userId": "[email protected]", | ||
"lastName": "Allani", | ||
"firstName": "Karim", | ||
"department": null, | ||
"phoneNumber": "+1-2025551234", | ||
"phoneNumberActivated": false, | ||
"emailAddress": "[email protected]", | ||
"hiraganaLastName": "Allani", | ||
"hiraganaFirstName": "Karim", | ||
"inTrunkGroup": false, | ||
"extension": "234", | ||
"countryCode": 1, | ||
"nationalPrefix": null, | ||
"domain": "alliedtelecom.net" | ||
}, | ||
"data": { | ||
"registrations": [], | ||
"userId": "[email protected]" | ||
} | ||
} | ||
] | ||
} | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,58 @@ | ||
--- | ||
description: my_api.get.user_regsitration() | ||
--- | ||
|
||
# 💚 User Registration | ||
|
||
Gets a users devices and if those devices are registered. This includes soft phones. | ||
|
||
### Parameters  | ||
|
||
* user\_id (str): Target user ID to check registration | ||
|
||
### Returns | ||
|
||
* dict: All users devices and details on device such as registration. | ||
|
||
### How To Use: | ||
|
||
{% code overflow="wrap" %} | ||
```python | ||
from odins_spear import api | ||
|
||
my_api= api.Api(base_url="https://base_url/api/vx", username="john.smith", password="ODIN_INSTANCE_1") | ||
my_api.authenticate() | ||
|
||
my_api.get.user_registration( | ||
"[email protected]" | ||
) | ||
``` | ||
{% endcode %} | ||
|
||
### Example Returned Data of SIP Passwords (Formatted) | ||
|
||
```json | ||
{ | ||
"registrations": [ | ||
{ | ||
"deviceLevel": "Group", | ||
"deviceName": "ECG_0004f2accaf7", | ||
"order": 1, | ||
"uRI": "sip:[email protected]:5060;transport=udp;jtr=22-1808", | ||
"expiration": "Thu May 23 08:33:00 EDT 2019", | ||
"line/Port": "[email protected]", | ||
"endpointType": "Primary", | ||
"publicNetAddress": null, | ||
"publicPort": null, | ||
"privateNetAddress": null, | ||
"privatePort": null, | ||
"userAgent": "Polycom/5.4.1.14510 PolycomVVX-VVX_500-UA/5.4.1.14510", | ||
"lockoutStarted": null, | ||
"lockoutExpires": null, | ||
"lockoutCount": 0, | ||
"accessInfo": null | ||
} | ||
], | ||
"userId": "[email protected]" | ||
} | ||
``` |