mirror of
https://github.com/davidhalter/typeshed.git
synced 2026-02-25 19:17:16 +08:00
Add defaults for third-party stubs A-D (#9952)
This commit is contained in:
@@ -14,13 +14,13 @@ class Address(Resource):
|
||||
Electronic: str
|
||||
ShipToStore: str
|
||||
@staticmethod
|
||||
def create(params: Incomplete | None = ...): ...
|
||||
def create(params: Incomplete | None = None): ...
|
||||
@staticmethod
|
||||
def delete(customer_id, address_id): ...
|
||||
@staticmethod
|
||||
def find(customer_id, address_id): ...
|
||||
@staticmethod
|
||||
def update(customer_id, address_id, params: Incomplete | None = ...): ...
|
||||
def update(customer_id, address_id, params: Incomplete | None = None): ...
|
||||
@staticmethod
|
||||
def create_signature(): ...
|
||||
@staticmethod
|
||||
|
||||
@@ -11,7 +11,7 @@ class AddressGateway:
|
||||
gateway: Any
|
||||
config: Any
|
||||
def __init__(self, gateway) -> None: ...
|
||||
def create(self, params: Incomplete | None = ...): ...
|
||||
def create(self, params: Incomplete | None = None): ...
|
||||
def delete(self, customer_id, address_id): ...
|
||||
def find(self, customer_id, address_id): ...
|
||||
def update(self, customer_id, address_id, params: Incomplete | None = ...): ...
|
||||
def update(self, customer_id, address_id, params: Incomplete | None = None): ...
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
from _typeshed import Incomplete
|
||||
|
||||
class AttributeGetter:
|
||||
def __init__(self, attributes: Incomplete | None = ...) -> None: ...
|
||||
def __init__(self, attributes: Incomplete | None = None) -> None: ...
|
||||
|
||||
@@ -58,4 +58,4 @@ class BraintreeGateway:
|
||||
verification: Any
|
||||
webhook_notification: Any
|
||||
webhook_testing: Any
|
||||
def __init__(self, config: Incomplete | None = ..., **kwargs) -> None: ...
|
||||
def __init__(self, config: Incomplete | None = None, **kwargs) -> None: ...
|
||||
|
||||
@@ -7,6 +7,6 @@ from braintree.util.crypto import Crypto as Crypto
|
||||
|
||||
class ClientToken:
|
||||
@staticmethod
|
||||
def generate(params: Incomplete | None = ..., gateway: Incomplete | None = ...): ...
|
||||
def generate(params: Incomplete | None = None, gateway: Incomplete | None = None): ...
|
||||
@staticmethod
|
||||
def generate_signature(): ...
|
||||
|
||||
@@ -9,4 +9,4 @@ class ClientTokenGateway:
|
||||
gateway: Any
|
||||
config: Any
|
||||
def __init__(self, gateway) -> None: ...
|
||||
def generate(self, params: Incomplete | None = ...): ...
|
||||
def generate(self, params: Incomplete | None = None): ...
|
||||
|
||||
@@ -30,13 +30,13 @@ class Configuration:
|
||||
wrap_http_exceptions: Any
|
||||
def __init__(
|
||||
self,
|
||||
environment: Incomplete | None = ...,
|
||||
merchant_id: Incomplete | None = ...,
|
||||
public_key: Incomplete | None = ...,
|
||||
private_key: Incomplete | None = ...,
|
||||
client_id: Incomplete | None = ...,
|
||||
client_secret: Incomplete | None = ...,
|
||||
access_token: Incomplete | None = ...,
|
||||
environment: Incomplete | None = None,
|
||||
merchant_id: Incomplete | None = None,
|
||||
public_key: Incomplete | None = None,
|
||||
private_key: Incomplete | None = None,
|
||||
client_id: Incomplete | None = None,
|
||||
client_secret: Incomplete | None = None,
|
||||
access_token: Incomplete | None = None,
|
||||
*args,
|
||||
**kwargs,
|
||||
) -> None: ...
|
||||
|
||||
@@ -9,7 +9,7 @@ class CredentialsParser:
|
||||
client_secret: Any
|
||||
access_token: Any
|
||||
def __init__(
|
||||
self, client_id: Incomplete | None = ..., client_secret: Incomplete | None = ..., access_token: Incomplete | None = ...
|
||||
self, client_id: Incomplete | None = None, client_secret: Incomplete | None = None, access_token: Incomplete | None = None
|
||||
) -> None: ...
|
||||
environment: Any
|
||||
def parse_client_credentials(self) -> None: ...
|
||||
|
||||
@@ -45,9 +45,9 @@ class CreditCard(Resource):
|
||||
Prepaid: Any
|
||||
ProductId: Any
|
||||
@staticmethod
|
||||
def create(params: Incomplete | None = ...): ...
|
||||
def create(params: Incomplete | None = None): ...
|
||||
@staticmethod
|
||||
def update(credit_card_token, params: Incomplete | None = ...): ...
|
||||
def update(credit_card_token, params: Incomplete | None = None): ...
|
||||
@staticmethod
|
||||
def delete(credit_card_token): ...
|
||||
@staticmethod
|
||||
|
||||
@@ -13,11 +13,11 @@ class CreditCardGateway:
|
||||
gateway: Any
|
||||
config: Any
|
||||
def __init__(self, gateway) -> None: ...
|
||||
def create(self, params: Incomplete | None = ...): ...
|
||||
def create(self, params: Incomplete | None = None): ...
|
||||
def delete(self, credit_card_token): ...
|
||||
def expired(self): ...
|
||||
def expiring_between(self, start_date, end_date): ...
|
||||
def find(self, credit_card_token): ...
|
||||
def forward(self, credit_card_token, receiving_merchant_id) -> None: ...
|
||||
def from_nonce(self, nonce): ...
|
||||
def update(self, credit_card_token, params: Incomplete | None = ...): ...
|
||||
def update(self, credit_card_token, params: Incomplete | None = None): ...
|
||||
|
||||
@@ -26,15 +26,15 @@ class Customer(Resource):
|
||||
@staticmethod
|
||||
def all(): ...
|
||||
@staticmethod
|
||||
def create(params: Incomplete | None = ...): ...
|
||||
def create(params: Incomplete | None = None): ...
|
||||
@staticmethod
|
||||
def delete(customer_id): ...
|
||||
@staticmethod
|
||||
def find(customer_id, association_filter_id: Incomplete | None = ...): ...
|
||||
def find(customer_id, association_filter_id: Incomplete | None = None): ...
|
||||
@staticmethod
|
||||
def search(*query): ...
|
||||
@staticmethod
|
||||
def update(customer_id, params: Incomplete | None = ...): ...
|
||||
def update(customer_id, params: Incomplete | None = None): ...
|
||||
@staticmethod
|
||||
def create_signature(): ...
|
||||
@staticmethod
|
||||
|
||||
@@ -14,8 +14,8 @@ class CustomerGateway:
|
||||
config: Any
|
||||
def __init__(self, gateway) -> None: ...
|
||||
def all(self): ...
|
||||
def create(self, params: Incomplete | None = ...): ...
|
||||
def create(self, params: Incomplete | None = None): ...
|
||||
def delete(self, customer_id): ...
|
||||
def find(self, customer_id, association_filter_id: Incomplete | None = ...): ...
|
||||
def find(self, customer_id, association_filter_id: Incomplete | None = None): ...
|
||||
def search(self, *query): ...
|
||||
def update(self, customer_id, params: Incomplete | None = ...): ...
|
||||
def update(self, customer_id, params: Incomplete | None = None): ...
|
||||
|
||||
@@ -8,7 +8,7 @@ class DocumentUpload(Resource):
|
||||
class Kind:
|
||||
EvidenceDocument: str
|
||||
@staticmethod
|
||||
def create(params: Incomplete | None = ...): ...
|
||||
def create(params: Incomplete | None = None): ...
|
||||
@staticmethod
|
||||
def create_signature(): ...
|
||||
def __init__(self, gateway, attributes) -> None: ...
|
||||
|
||||
@@ -10,4 +10,4 @@ class DocumentUploadGateway:
|
||||
gateway: Any
|
||||
config: Any
|
||||
def __init__(self, gateway) -> None: ...
|
||||
def create(self, params: Incomplete | None = ...): ...
|
||||
def create(self, params: Incomplete | None = None): ...
|
||||
|
||||
@@ -7,7 +7,7 @@ class Environment:
|
||||
is_ssl: Any
|
||||
ssl_certificate: Any
|
||||
def __init__(
|
||||
self, name, server, port, auth_url, is_ssl, ssl_certificate, graphql_server: str = ..., graphql_port: str = ...
|
||||
self, name, server, port, auth_url, is_ssl, ssl_certificate, graphql_server: str = "", graphql_port: str = ""
|
||||
) -> None: ...
|
||||
@property
|
||||
def base_url(self): ...
|
||||
|
||||
@@ -26,7 +26,7 @@ class MerchantAccount(Resource):
|
||||
master_merchant_account: Any
|
||||
def __init__(self, gateway, attributes) -> None: ...
|
||||
@staticmethod
|
||||
def create(params: Incomplete | None = ...): ...
|
||||
def create(params: Incomplete | None = None): ...
|
||||
@staticmethod
|
||||
def update(id, attributes): ...
|
||||
@staticmethod
|
||||
|
||||
@@ -14,8 +14,8 @@ class MerchantAccountGateway:
|
||||
gateway: Any
|
||||
config: Any
|
||||
def __init__(self, gateway) -> None: ...
|
||||
def create(self, params: Incomplete | None = ...): ...
|
||||
def update(self, merchant_account_id, params: Incomplete | None = ...): ...
|
||||
def create(self, params: Incomplete | None = None): ...
|
||||
def update(self, merchant_account_id, params: Incomplete | None = None): ...
|
||||
def find(self, merchant_account_id): ...
|
||||
def create_for_currency(self, params: Incomplete | None = ...): ...
|
||||
def create_for_currency(self, params: Incomplete | None = None): ...
|
||||
def all(self): ...
|
||||
|
||||
@@ -6,13 +6,13 @@ from braintree.resource import Resource as Resource
|
||||
|
||||
class PaymentMethod(Resource):
|
||||
@staticmethod
|
||||
def create(params: Incomplete | None = ...): ...
|
||||
def create(params: Incomplete | None = None): ...
|
||||
@staticmethod
|
||||
def find(payment_method_token): ...
|
||||
@staticmethod
|
||||
def update(payment_method_token, params): ...
|
||||
@staticmethod
|
||||
def delete(payment_method_token, options: Incomplete | None = ...): ...
|
||||
def delete(payment_method_token, options: Incomplete | None = None): ...
|
||||
@staticmethod
|
||||
def create_signature(): ...
|
||||
@staticmethod
|
||||
|
||||
@@ -27,10 +27,10 @@ class PaymentMethodGateway:
|
||||
gateway: Any
|
||||
config: Any
|
||||
def __init__(self, gateway) -> None: ...
|
||||
def create(self, params: Incomplete | None = ...): ...
|
||||
def create(self, params: Incomplete | None = None): ...
|
||||
def find(self, payment_method_token): ...
|
||||
def update(self, payment_method_token, params): ...
|
||||
def delete(self, payment_method_token, options: Incomplete | None = ...): ...
|
||||
def delete(self, payment_method_token, options: Incomplete | None = None): ...
|
||||
options: Any
|
||||
def grant(self, payment_method_token, options: Incomplete | None = ...): ...
|
||||
def grant(self, payment_method_token, options: Incomplete | None = None): ...
|
||||
def revoke(self, payment_method_token): ...
|
||||
|
||||
@@ -7,7 +7,7 @@ from braintree.three_d_secure_info import ThreeDSecureInfo as ThreeDSecureInfo
|
||||
|
||||
class PaymentMethodNonce(Resource):
|
||||
@staticmethod
|
||||
def create(payment_method_token, params=...): ...
|
||||
def create(payment_method_token, params={}): ...
|
||||
@staticmethod
|
||||
def find(payment_method_nonce): ...
|
||||
three_d_secure_info: Any
|
||||
|
||||
@@ -10,7 +10,7 @@ class PayPalAccount(Resource):
|
||||
@staticmethod
|
||||
def delete(paypal_account_token): ...
|
||||
@staticmethod
|
||||
def update(paypal_account_token, params: Incomplete | None = ...): ...
|
||||
def update(paypal_account_token, params: Incomplete | None = None): ...
|
||||
@staticmethod
|
||||
def signature(): ...
|
||||
subscriptions: Any
|
||||
|
||||
@@ -13,4 +13,4 @@ class PayPalAccountGateway:
|
||||
def __init__(self, gateway) -> None: ...
|
||||
def find(self, paypal_account_token): ...
|
||||
def delete(self, paypal_account_token): ...
|
||||
def update(self, paypal_account_token, params: Incomplete | None = ...): ...
|
||||
def update(self, paypal_account_token, params: Incomplete | None = None): ...
|
||||
|
||||
@@ -40,12 +40,12 @@ class Search:
|
||||
class MultipleValueNodeBuilder:
|
||||
name: Any
|
||||
whitelist: Any
|
||||
def __init__(self, name, whitelist=...) -> None: ...
|
||||
def __init__(self, name, whitelist=[]) -> None: ...
|
||||
def in_list(self, *values): ...
|
||||
def __eq__(self, value): ...
|
||||
|
||||
class MultipleValueOrTextNodeBuilder(TextNodeBuilder, MultipleValueNodeBuilder):
|
||||
def __init__(self, name, whitelist=...) -> None: ...
|
||||
def __init__(self, name, whitelist=[]) -> None: ...
|
||||
|
||||
class RangeNodeBuilder:
|
||||
name: Any
|
||||
|
||||
@@ -10,4 +10,4 @@ from braintree.util.http import Http as Http
|
||||
|
||||
class SettlementBatchSummary(Resource):
|
||||
@staticmethod
|
||||
def generate(settlement_date, group_by_custom_field: Incomplete | None = ...): ...
|
||||
def generate(settlement_date, group_by_custom_field: Incomplete | None = None): ...
|
||||
|
||||
@@ -10,4 +10,4 @@ class SettlementBatchSummaryGateway:
|
||||
gateway: Any
|
||||
config: Any
|
||||
def __init__(self, gateway) -> None: ...
|
||||
def generate(self, settlement_date, group_by_custom_field: Incomplete | None = ...): ...
|
||||
def generate(self, settlement_date, group_by_custom_field: Incomplete | None = None): ...
|
||||
|
||||
@@ -31,15 +31,15 @@ class Subscription(Resource):
|
||||
PastDue: str
|
||||
Pending: str
|
||||
@staticmethod
|
||||
def create(params: Incomplete | None = ...): ...
|
||||
def create(params: Incomplete | None = None): ...
|
||||
@staticmethod
|
||||
def create_signature(): ...
|
||||
@staticmethod
|
||||
def find(subscription_id): ...
|
||||
@staticmethod
|
||||
def retry_charge(subscription_id, amount: Incomplete | None = ..., submit_for_settlement: bool = ...): ...
|
||||
def retry_charge(subscription_id, amount: Incomplete | None = None, submit_for_settlement: bool = False): ...
|
||||
@staticmethod
|
||||
def update(subscription_id, params: Incomplete | None = ...): ...
|
||||
def update(subscription_id, params: Incomplete | None = None): ...
|
||||
@staticmethod
|
||||
def cancel(subscription_id): ...
|
||||
@staticmethod
|
||||
|
||||
@@ -14,8 +14,8 @@ class SubscriptionGateway:
|
||||
config: Any
|
||||
def __init__(self, gateway) -> None: ...
|
||||
def cancel(self, subscription_id): ...
|
||||
def create(self, params: Incomplete | None = ...): ...
|
||||
def create(self, params: Incomplete | None = None): ...
|
||||
def find(self, subscription_id): ...
|
||||
def retry_charge(self, subscription_id, amount: Incomplete | None = ..., submit_for_settlement: bool = ...): ...
|
||||
def retry_charge(self, subscription_id, amount: Incomplete | None = None, submit_for_settlement: bool = False): ...
|
||||
def search(self, *query): ...
|
||||
def update(self, subscription_id, params: Incomplete | None = ...): ...
|
||||
def update(self, subscription_id, params: Incomplete | None = None): ...
|
||||
|
||||
@@ -8,7 +8,7 @@ class TestingGateway:
|
||||
gateway: Any
|
||||
config: Any
|
||||
def __init__(self, gateway) -> None: ...
|
||||
def make_past_due(self, subscription_id, number_of_days_past_due: int = ...) -> None: ...
|
||||
def make_past_due(self, subscription_id, number_of_days_past_due: int = 1) -> None: ...
|
||||
def escrow_transaction(self, transaction_id) -> None: ...
|
||||
def settle_transaction(self, transaction_id): ...
|
||||
def settlement_confirm_transaction(self, transaction_id): ...
|
||||
|
||||
@@ -104,23 +104,23 @@ class Transaction(Resource):
|
||||
@staticmethod
|
||||
def cancel_release(transaction_id): ...
|
||||
@staticmethod
|
||||
def credit(params: Incomplete | None = ...): ...
|
||||
def credit(params: Incomplete | None = None): ...
|
||||
@staticmethod
|
||||
def find(transaction_id): ...
|
||||
@staticmethod
|
||||
def hold_in_escrow(transaction_id): ...
|
||||
@staticmethod
|
||||
def refund(transaction_id, amount_or_options: Incomplete | None = ...): ...
|
||||
def refund(transaction_id, amount_or_options: Incomplete | None = None): ...
|
||||
@staticmethod
|
||||
def sale(params: Incomplete | None = ...): ...
|
||||
def sale(params: Incomplete | None = None): ...
|
||||
@staticmethod
|
||||
def search(*query): ...
|
||||
@staticmethod
|
||||
def release_from_escrow(transaction_id): ...
|
||||
@staticmethod
|
||||
def submit_for_settlement(transaction_id, amount: Incomplete | None = ..., params: Incomplete | None = ...): ...
|
||||
def submit_for_settlement(transaction_id, amount: Incomplete | None = None, params: Incomplete | None = None): ...
|
||||
@staticmethod
|
||||
def update_details(transaction_id, params: Incomplete | None = ...): ...
|
||||
def update_details(transaction_id, params: Incomplete | None = None): ...
|
||||
@staticmethod
|
||||
def void(transaction_id): ...
|
||||
@staticmethod
|
||||
@@ -136,7 +136,7 @@ class Transaction(Resource):
|
||||
@staticmethod
|
||||
def refund_signature(): ...
|
||||
@staticmethod
|
||||
def submit_for_partial_settlement(transaction_id, amount, params: Incomplete | None = ...): ...
|
||||
def submit_for_partial_settlement(transaction_id, amount, params: Incomplete | None = None): ...
|
||||
amount: Any
|
||||
tax_amount: Any
|
||||
discount_amount: Any
|
||||
|
||||
@@ -20,11 +20,11 @@ class TransactionGateway:
|
||||
def credit(self, params): ...
|
||||
def find(self, transaction_id): ...
|
||||
def hold_in_escrow(self, transaction_id): ...
|
||||
def refund(self, transaction_id, amount_or_options: Incomplete | None = ...): ...
|
||||
def refund(self, transaction_id, amount_or_options: Incomplete | None = None): ...
|
||||
def sale(self, params): ...
|
||||
def search(self, *query): ...
|
||||
def release_from_escrow(self, transaction_id): ...
|
||||
def submit_for_settlement(self, transaction_id, amount: Incomplete | None = ..., params: Incomplete | None = ...): ...
|
||||
def update_details(self, transaction_id, params: Incomplete | None = ...): ...
|
||||
def submit_for_partial_settlement(self, transaction_id, amount, params: Incomplete | None = ...): ...
|
||||
def submit_for_settlement(self, transaction_id, amount: Incomplete | None = None, params: Incomplete | None = None): ...
|
||||
def update_details(self, transaction_id, params: Incomplete | None = None): ...
|
||||
def submit_for_partial_settlement(self, transaction_id, amount, params: Incomplete | None = None): ...
|
||||
def void(self, transaction_id): ...
|
||||
|
||||
@@ -15,5 +15,5 @@ class GraphQLClient(Http):
|
||||
@staticmethod
|
||||
def raise_exception_for_graphql_error(response) -> None: ...
|
||||
graphql_headers: Any
|
||||
def __init__(self, config: Incomplete | None = ..., environment: Incomplete | None = ...) -> None: ...
|
||||
def query(self, definition, variables: Incomplete | None = ..., operation_name: Incomplete | None = ...): ...
|
||||
def __init__(self, config: Incomplete | None = None, environment: Incomplete | None = None) -> None: ...
|
||||
def query(self, definition, variables: Incomplete | None = None, operation_name: Incomplete | None = None): ...
|
||||
|
||||
@@ -30,14 +30,14 @@ class Http:
|
||||
@staticmethod
|
||||
def is_error_status(status): ...
|
||||
@staticmethod
|
||||
def raise_exception_from_status(status, message: Incomplete | None = ...) -> None: ...
|
||||
def raise_exception_from_status(status, message: Incomplete | None = None) -> None: ...
|
||||
config: Any
|
||||
environment: Any
|
||||
def __init__(self, config, environment: Incomplete | None = ...) -> None: ...
|
||||
def post(self, path, params: Incomplete | None = ...): ...
|
||||
def __init__(self, config, environment: Incomplete | None = None) -> None: ...
|
||||
def post(self, path, params: Incomplete | None = None): ...
|
||||
def delete(self, path): ...
|
||||
def get(self, path): ...
|
||||
def put(self, path, params: Incomplete | None = ...): ...
|
||||
def post_multipart(self, path, files, params: Incomplete | None = ...): ...
|
||||
def put(self, path, params: Incomplete | None = None): ...
|
||||
def post_multipart(self, path, files, params: Incomplete | None = None): ...
|
||||
def http_do(self, http_verb, path, headers, request_body): ...
|
||||
def handle_exception(self, exception) -> None: ...
|
||||
|
||||
@@ -5,7 +5,7 @@ from braintree.validation_error import ValidationError as ValidationError
|
||||
|
||||
class ValidationErrorCollection:
|
||||
data: Any
|
||||
def __init__(self, data: Incomplete | None = ...) -> None: ...
|
||||
def __init__(self, data: Incomplete | None = None) -> None: ...
|
||||
@property
|
||||
def deep_errors(self): ...
|
||||
def for_index(self, index): ...
|
||||
|
||||
@@ -4,4 +4,4 @@ from braintree.configuration import Configuration as Configuration
|
||||
|
||||
class WebhookTesting:
|
||||
@staticmethod
|
||||
def sample_notification(kind, id, source_merchant_id: Incomplete | None = ...): ...
|
||||
def sample_notification(kind, id, source_merchant_id: Incomplete | None = None): ...
|
||||
|
||||
@@ -8,4 +8,4 @@ class WebhookTestingGateway:
|
||||
gateway: Any
|
||||
config: Any
|
||||
def __init__(self, gateway) -> None: ...
|
||||
def sample_notification(self, kind, id, source_merchant_id: Incomplete | None = ...): ...
|
||||
def sample_notification(self, kind, id, source_merchant_id: Incomplete | None = None): ...
|
||||
|
||||
Reference in New Issue
Block a user