Welcome to the Onshape forum! Ask questions and join in the discussions about everything Onshape.
First time visiting? Here are some places to start:- Looking for a certain topic? Check out the categories filter or use Search (upper right).
- Need support? Ask a question to our Community Support category.
- Please submit support tickets for bugs but you can request improvements in the Product Feedback category.
- Be respectful, on topic and if you see a problem, Flag it.
If you would like to contact our Community Manager personally, feel free to send a private message or an email.
Making a request to the API to add emails to OnShape team
carl_malagodi
Member Posts: 18 EDU
I have a excel file of email files, Is there some way that I can make an API request with all of those emails to add them to a team that I own? If this is possible would it become an issue if I tried to add an email that was already inside the team?
0
Comments
/api/teams/{teamid}/members
with the body:
{
"admin":false,
"email": "john@company.com"
}
If you try to add a team member that is already on the team, you will just get a 409 conflict code back.
If you try to add a team member that does not exist, that email address will get an invitation email.
If you want an easy way to do authentication, you can download one of the sample apps that Onshape has created from their github. They are a great starting point. They even have one for c#.
Or if you want to start with postman, you can check out my post in this thread, and replicate that process.
To get the team id, browse to the page that lets you edit a team.
The url for that page is in the form of https://cad.onshape.com/companySettings/{company id}/teams/{team id}