From 12acb56ae97daa31d7d1bebc8e74d084d41cfcf6 Mon Sep 17 00:00:00 2001 From: Salama Balekage Date: Wed, 8 Nov 2023 10:08:39 +0300 Subject: [PATCH] Remove isPromoBundle field from mobile data request --- README.md | 147 +---------------------------------- africastalking/MobileData.py | 1 - 2 files changed, 2 insertions(+), 146 deletions(-) diff --git a/README.md b/README.md index 37e4b15..dd848af 100644 --- a/README.md +++ b/README.md @@ -74,7 +74,7 @@ Initialize the SDK by calling `africastalking.initialize(username, api_key)`. Af - [Voice](#voice): `africastalking.Voice` - [Token](#token): `africastalking.Token` - [Application](#application): `africastalking.Application` -- [MobileData](#mobiledata): `africastalking.MobileData` +- [Mobile Data](#mobiledata): `africastalking.MobileData` ### `Application` @@ -131,148 +131,6 @@ Initialize the SDK by calling `africastalking.initialize(username, api_key)`. Af - `short_code`: Premium short code mapped to your account. `REQUIRED` - `keyword`: Premium keyword under the above short code and is also mapped to your account. `REQUIRED` - `phone_number`: PhoneNumber to be subscribed `REQUIRED` - - - + - `url`: The url of the file to upload. Should start with `http(s)://`. `REQUIRED` ### `MobileData` @@ -301,7 +159,6 @@ Initialize the SDK by calling `africastalking.initialize(username, api_key)`. Af - `quantity`: Mobile data amount. `REQUIRED` - `unit`: Mobile data unit. Can either be `MB` or `GB`. `REQUIRED` - `validity`: How long the mobile data is valid for. Must be one of `Day`, `Week` and `Month`. `REQUIRED` - - `isPromoBundle`: This is an optional field that can be either`true` and `false`. `OPTIONAL` - `metadata`: Additional data to associate with the transaction. `OPTIONAL` - `find_transaction(transaction_id: str)`: Find a mobile data transaction. diff --git a/africastalking/MobileData.py b/africastalking/MobileData.py index e7e75c8..673f09c 100644 --- a/africastalking/MobileData.py +++ b/africastalking/MobileData.py @@ -27,7 +27,6 @@ def send(self, product_name, recipients, callback=None): "quantity": And(lambda f: float(f) > 0), "unit": And(str, lambda s: validate_data_units(s)), "validity": And(str, lambda s: validate_data_validity(s)), - Optional("isPromoBundle"): And(bool), Optional("metadata"): And(dict), } ]