Welcome to the Onshape forum! Ask questions and join in the discussions about everything Onshape.

First time visiting? Here are some places to start:
  1. Looking for a certain topic? Check out the categories filter or use Search (upper right).
  2. Need support? Ask a question to our Community Support category.
  3. Please submit support tickets for bugs but you can request improvements in the Product Feedback category.
  4. 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.

Internal Error has occured when using Rest API to assign variables to variable studio

Soham_SinhaSoham_Sinha Member Posts: 4 EDU
Hi all!

I am using the Rest API - specifically, the POST method to assign variables to variable studios (url link /variables/d/{did}/w/{wid}/e/{eid}/variables).

I have been following the Glassworks example in the API for the body of the request: (Below is a test example)

[
  {
    "description": "test",
    "expression": "150 mm",
    "name": "date",
    "type": "Length"
  }
]

However, I keep getting an internal error shown below. 

Is there an internal bug here? 

I have tested this in other documents - I can create a variable studio using the Rest API, but every time I try to assign variables to the variable studio, the POST fails with a message. "An Internal error has occured"

{
  "message": "An internal error has occurred; support code eab8dbd66b6f662dc1040301",
  "supportCode": "eab8dbd66b6f662dc1040301",
  "moreInfoUrl": "",
  "status": 500,
  "code": 0
}

Best Answer

  • _anton_anton Member, Onshape Employees Posts: 410
    Answer ✓
    Try "Length" -> "LENGTH"

Answers

  • _anton_anton Member, Onshape Employees Posts: 410
    Answer ✓
    Try "Length" -> "LENGTH"
  • Soham_SinhaSoham_Sinha Member Posts: 4 EDU
    Yes thank you! Found out a few minutes after I posted this. 
Sign In or Register to comment.