jsonsystems / json-schema

JSONSchema.Net Public Repository
Apache License 2.0
663 stars 64 forks source link

Error creating JSON schema #101

Closed thorai219 closed 4 years ago

thorai219 commented 4 years ago

It's been like this for few days, what am i doing wrong? Screenshot from 2020-10-07 10-59-38

jackwootton commented 4 years ago

@thorai219 Thanks for posting this. How do you login (GitHub, Google, Guest)? I can only see one error with the inferGraph API call on the backed

Method: jsonschema.v1.JsonSchema.InferGraph failed: DATA_LOSS: Invalid base64-encoded string: number of data characters (897) cannot be 1 more than a multiple of 4"

This looks like an issue with the JWT. Can you post the JWT here? You'll need to use the Developer Console to inspect the network call to https://prod.json.systems/v1/graphs:inferGraph?key=AIzaSyDOzK6DXqsLvq57cxa5Y7o6_TkMZ1SS3bk. From there you should be able to see the authorization header which will contain something like

authorization: Bearer eyJhbGciOiJSUzI1NiIsImtpZCI6IjE2NzUwM2UwYWVjNTJkZGZiODk2NTIxYjkxN2ZiOGUyMGMxZjMzMDAiLCJ0eXAiOiJKV1QifQ.eyJpc3MiOiJodHRwczovL3NlY3VyZXRva2VuLmdvb2dsZS5jb20vanNvbi1zY2hlbWEiLCJhdWQiOiJqc29uLXNjaGVtYSIsImF1dGhfdGltZSI6MTYwMDc2NDM1OSwidXNlcl9pZCI6IlRpMjIwVXB1bEFWTk8zWGhkck4xdjdEbFdTbDEiLCJzdWIiOiJUaTIyMFVwdWxBVk5PM1hoZHJOMXY3RGxXU2wxIiwiaWF0IjoxNjAyMDk2MjYzLCJleHAiOjE2MDIwOTk4NjMsImVtYWlsIjoiamFja3dvb3R0b25AZ21haWwuY2NvbSIsImVtYWlsX3ZlcmlmaWVkIjpmYWxzZSwiZmlyZWJhc2UiOnsiaWRlbnRpdGllcyI6eyJlbWFpbCI6WyJqYWNrd29vdHRvbkBnbWFpbC5jY29tIl19LCJzaWduX2luX3Byb3ZpZGVyIjoicGFzc3dvcmQifX0.NgieNvisel0BqYJ09LJr6SxWMpCu

If you don't want to post it here, can you check it decodes successfully with https://jwt.io?