1.4.5 • Published 3 years ago

@snapp-store/miare-sdk v1.4.5

Weekly downloads
-
License
MIT
Repository
github
Last release
3 years ago

miare-sdk

Miare SDK is a Typescript library for dealing with mia.re 3rd party api 🛵.

Installation

Use the package manager npm to install miare-sdk.

npm install @snapp-store/miare-sdk

Usage

Pass your API key and environment between "staging" or "production" to Miare class and create an instance of it.

import Miare from '@snapp-store/miare-sdk';

const miare = new Miare('<YOUR_MIARE_API_KEY>', 'staging');

const someFancyFunction = async () => {
  // some loginc here

  const canceledTrips = await miare.getTrips({ state: 'canceled_by_client' });

  return canceledTrips;
};

Available Methods

  • createTrip(createTripParameters)
  • addCourseToTrip(tripid, newCourse)
  • removeCourseFromTrip(courseId)
  • cancelTripById(tripId)
  • getTripById(tripId)
  • getTrips(getTripsParameters)
  • getEstimatePrice(source, destination)
  • getAreas()

Contributing

Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.

Please make sure to update tests as appropriate.

License

MIT

1.4.5

3 years ago

1.3.5

3 years ago

1.3.4

3 years ago

1.3.3

3 years ago

1.3.2

3 years ago

1.3.1

3 years ago

1.2.1

3 years ago

1.2.0

3 years ago

1.1.0

3 years ago

1.0.0

3 years ago