"Unauthorized" error when used email-like token

Hi guys, I kept getting Error 401 (“Unauthorized”) when using my email address as the ApiToken.

(FYI, the bearer token method with the token string obtained from https://www.rhino3d.com/compute/login still works for me)

1 Like

Yes, we’ve been making a lot of changes to compute lately. You now need to use the bearer token method that you already figured out.

1 Like

Ah I see, thanks for the clarification.

Playing with compute and rhino3dm at the moment and have some issues.

If I use example from

I paste token and everything is ok but if I don’t want to use Tkinter and try to store token in document as

auth_token = “mytoken”
compute_rhino3d.Util.authToken = auth_token

everything goes south…
get errors like

Traceback (most recent call last):
File “/home/lukasz/.local/lib/python2.7/site-packages/compute_rhino3d/Curve.py”, line 552, in Split
response = Util.ComputeFetch(“rhino/geometry/curve/split-curve_brep_double”, args)
File “/home/lukasz/.local/lib/python2.7/site-packages/compute_rhino3d/Util.py”, line 17, in ComputeFetch
response = urllib2.urlopen(req, json.dumps(args))
File “/usr/lib/python2.7/json/init.py”, line 244, in dumps
return _default_encoder.encode(obj)
File “/usr/lib/python2.7/json/encoder.py”, line 207, in encode
chunks = self.iterencode(o, _one_shot=True)
File “/usr/lib/python2.7/json/encoder.py”, line 270, in iterencode
return _iterencode(o, 0)
File “/usr/lib/python2.7/json/encoder.py”, line 184, in default
raise TypeError(repr(o) + " is not JSON serializable")
TypeError: <rhino3dm._rhino3dm.Circle object at 0x7fd41d28bb90> is not JSON serializable

I’m sure I’m doing something wrong.

The other thing is when I look at
https://compute.rhino3d.com/sdk
there is tons of stuff but when I import compute_rhino3d.

I only get
-Curve
-Brep
-Util
-Extrusion
-NurbsCurve
-BezierCurve

My rhino3dm is in 0.0.7 and compute_rhino3d in 0.0.5
Running on Python 2.7 using Pycharm in virtualbox (ubuntu)

PS. I think rhino3dm and compute is a killer project!!

Is this a new problem? If so, please post as a new topic. I can’t tell if this is a question about using the authorization token from www.rhino3d.com/compute/login

Sorry my bad I’ll make a new post and yes, it’s a question about using token from www.rhino3d.com/compute/login