I am facing with the problem of ModuleNotFoundError: No module named 'swagger_client' when trying to run the below code.
How it is possible to import swagger_client?
I want to have access to a custom api.
my code :
from __future__ import print_function
import time
import swagger_client
from swagger_client.rest import ApiException
from pprint import pprint
# create an instance of the API class
api_instance = swagger_client.BookingApi()
reservationId = # Long | reservation id
try:
# Cancel reservation
api_response = api_instance.cancel_reservation(reservationId)
pprint(api_response)
except ApiException as e:
print("Exception when calling BookingApi->cancelReservation: %s\n" % e)