Skip to content
This repository has been archived by the owner. It is now read-only.
/ shamash-gen Public archive

CLI for creating a shamash URL from raw graphql response or en-tur.no URL

Notifications You must be signed in to change notification settings

entur/shamash-gen

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

15 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

shamash-gen

Generer URL til shamash basert på rå respons fra f.eks. Chrome.

npm install --global @entur/shamash-gen

Bruk:

Usage: shamash-gen [options] <source>

Create a shamash URL from raw graphql response

Options:

  -V, --version  output the version number
  -d, --dev      Use dev environment
  -s, --staging  Use staging environment
  -h, --help     output usage information

Eksempel:

shamash-gen '{"query":"\n    query StopPlaces($id:String!) {\n        stopPlace(id:$id) {\n          id\n          name\n          latitude\n          longitude\n        }\n    }\n    ","variables":{"id":"NSR:StopPlace:6493"}}'

Gir følgende svar:

https://api.entur.io/journey-planner/v2/ide/?variables={"id":"NSR:StopPlace:6493"}&query=query StopPlaces($id:String!) {  stopPlace(id:$id) {  id  name  latitude  longitude  }  }

About

CLI for creating a shamash URL from raw graphql response or en-tur.no URL

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published