# Getting introspection from shiphero graphql with Python

**URL:** <https://community.shiphero.com/t/getting-introspection-from-shiphero-graphql-with-python/1927>\
**Category:** GraphQL API\
**Created:** [March 31, 2022, 4:32pm UTC](https://community.shiphero.com/t/getting-introspection-from-shiphero-graphql-with-python/1927 "2022-03-31T16:32:49Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![pipesanma](https://sea2.discourse-cdn.com/flex020/user_avatar/community.shiphero.com/pipesanma/32/515_2.png) [@pipesanma](https://community.shiphero.com/u/pipesanma)\
**Post date:** [March 31, 2022, 4:32pm UTC](https://community.shiphero.com/t/getting-introspection-from-shiphero-graphql-with-python/1927/1 "2022-03-31T16:32:50Z")

</div>

Hi there!

I’m trying to generate que json file from the [official doc](https://developer.shiphero.com/graphql-primer/#python)

```auto
python3 -m sgqlc.introspection \
 --exclude-deprecated \
 --exclude-description \
 -H "Authorization: Bearer YOUR_TOKEN" \ 
http://public-api.shiphero.com/graphql \ 
sh_public_api.json

```

But i’m getting the error:

```auto
{'errors': [{'message': 'Must provide query string.'}], 'exception': <HTTPError 400: 'BAD REQUEST'>, 'status': 400, 'headers': <http.client.HTTPMessage object at 0x10993df10>}

```

¿Could you help me please?

---

<div class="post-metadata">

**Author:** ![pipesanma](https://sea2.discourse-cdn.com/flex020/user_avatar/community.shiphero.com/pipesanma/32/515_2.png) [@pipesanma](https://community.shiphero.com/u/pipesanma)\
**Post date:** [April 1, 2022, 4:38pm UTC](https://community.shiphero.com/t/getting-introspection-from-shiphero-graphql-with-python/1927/2 "2022-04-01T16:38:15Z")

</div>

Nevermind, i found a solution

The URL was wrong; just change to https and works

python3 -m sgqlc.introspection   
–exclude-deprecated   
–exclude-description   
-H “Authorization: Bearer YOUR\_TOKEN” \  
**https** ://public-api.shiphero.com/graphql \  
sh\_public\_api.json
