Package: mailinabox-api
mailinabox-apiPython client SDK for the Mail-in-a-Box API.API version: 0.51.0Package version: 0.51.1https://pypi.org/project/mailinabox-apiNOTE:This package isauto-generatedfrom the Mail-In-A-Box OpenAPI spec.RequirementsPython 2.7 and 3.4+Installation & Usagepip installIf the python package is hosted on a repository, you can install directly using:pipinstallgit+https://github.com/badsyntax/mailinabox-api-py.git(you may need to runpipwith root permission:sudo pip install git+https://github.com/badsyntax/mailinabox-api-py.git)Then import the package:importmailinabox_apiSetuptoolsInstall viaSetuptools.pythonsetup.pyinstall--user(orsudo python setup.py installto install the package for all users)Then import the package:importmailinabox_apiGetting StartedPlease follow theinstallation procedureand then run the following:from__future__importprint_functionimporttimeimportmailinabox_apifrommailinabox_api.restimportApiExceptionfrompprintimportpprint# Defining the host is optional and defaults to https://box.example.com/admin# See configuration.py for a list of all supported configuration parameters.configuration=mailinabox_api.Configuration(host="https://box.example.com/admin")# The client must configure the authentication and authorization parameters# in accordance with the API server security policy.# Examples for each auth method are provided below, use the example that# satisfies your auth use case.# Configure HTTP basic authorization: basicAuthconfiguration=mailinabox_api.Configuration(username='YOUR_USERNAME',password='YOUR_PASSWORD')# Enter a context with an instance of the API clientwithmailinabox_api.ApiClient(configuration)asapi_client:# Create an instance of the API classapi_instance=mailinabox_api.DNSApi(api_client)qname='qname_example'# str | DNS query name.body=1.2.3.4# str |try:# Add DNS custom A recordapi_response=api_instance.add_dns_custom_a_record(qname,body)pprint(api_response)exceptApiExceptionase:print("Exception when calling DNSApi->add_dns_custom_a_record:%s\n"%e)Documentation for API EndpointsAll URIs are relative tohttps://box.example.com/adminClassMethodHTTP requestDescriptionDNSApiadd_dns_custom_a_recordPOST/dns/custom/{qname}Add DNS custom A recordDNSApiadd_dns_custom_recordPOST/dns/custom/{qname}/{rtype}Add DNS custom recordDNSApiadd_dns_secondary_nameserverPOST/dns/secondary-nameserverAdd DNS secondary nameserverDNSApiget_dns_custom_a_records_for_q_nameGET/dns/custom/{qname}Get DNS custom A recordsDNSApiget_dns_custom_recordsGET/dns/customGet DNS custom recordsDNSApiget_dns_custom_records_for_q_name_and_typeGET/dns/custom/{qname}/{rtype}Get DNS custom recordsDNSApiget_dns_dumpGET/dns/dumpGet DNS dumpDNSApiget_dns_secondary_nameserverGET/dns/secondary-nameserverGet DNS secondary nameserverDNSApiget_dns_zonefileGET/dns/zonefile/{zone}Get DNS zonefileDNSApiget_dns_zonesGET/dns/zonesGet DNS zonesDNSApiremove_dns_custom_a_recordDELETE/dns/custom/{qname}Remove DNS custom A recordDNSApiremove_dns_custom_recordDELETE/dns/custom/{qname}/{rtype}Remove DNS custom recordDNSApiupdate_dnsPOST/dns/updateUpdate DNSDNSApiupdate_dns_custom_a_recordPUT/dns/custom/{qname}Update DNS custom A recordDNSApiupdate_dns_custom_recordPUT/dns/custom/{qname}/{rtype}Update DNS custom recordMFAApimfa_statusPOST/mfa/statusRetrieve MFA status for you or another userMFAApimfa_totp_disablePOST/mfa/disableDisable multi-factor authentication for you or another userMFAApimfa_totp_enablePOST/mfa/totp/enableEnable TOTP authenticationMailApiadd_mail_userPOST/mail/users/addAdd mail userMailApiadd_mail_user_privilegePOST/mail/users/privileges/addAdd mail user privilegeMailApiget_mail_aliasesGET/mail/aliasesGet mail aliasesMailApiget_mail_domainsGET/mail/domainsGet mail domainsMailApiget_mail_user_privilegesGET/mail/users/privilegesGet mail user privilegesMailApiget_mail_usersGET/mail/usersGet mail usersMailApiremove_mail_aliasPOST/mail/aliases/removeRemove mail aliasMailApiremove_mail_userPOST/mail/users/removeRemove mail userMailApiremove_mail_user_privilegePOST/mail/users/privileges/removeRemove mail user privilegeMailApiset_mail_user_passwordPOST/mail/users/passwordSet mail user passwordMailApiupsert_mail_aliasPOST/mail/aliases/addUpsert mail aliasSSLApigenerate_sslcsrPOST/ssl/csr/{domain}Generate SSL CSRSSLApiget_ssl_statusGET/ssl/statusGet SSL statusSSLApiinstall_ssl_certificatePOST/ssl/installInstall SSL certificateSSLApiprovision_ssl_certificatesPOST/ssl/provisionProvision SSL certificatesSystemApiget_system_backup_configGET/system/backup/configGet system backup configSystemApiget_system_backup_statusGET/system/backup/statusGet system backup statusSystemApiget_system_privacy_statusGET/system/privacyGet system privacy statusSystemApiget_system_reboot_statusGET/system/rebootGet system reboot statusSystemApiget_system_statusPOST/system/statusGet system statusSystemApiget_system_updatesGET/system/updatesGet system updatesSystemApiget_system_upstream_versionPOST/system/latest-upstream-versionGet system upstream versionSystemApiget_system_versionGET/system/versionGet system versionSystemApireboot_systemPOST/system/rebootReboot systemSystemApiupdate_system_backup_configPOST/system/backup/configUpdate system backup configSystemApiupdate_system_packagesPOST/system/update-packagesUpdate system packagesSystemApiupdate_system_privacyPOST/system/privacyUpdate system privacyUserApiget_meGET/meGet user informationWebApiget_web_domainsGET/web/domainsGet web domainsWebApiupdate_webPOST/web/updateUpdate webDocumentation For ModelsDNSCustomRecordDNSCustomRecordsResponseDNSDumpDomainRecordDNSDumpDomainRecordsDNSDumpDomainsDNSDumpResponseDNSRecordTypeDNSSecondaryNameserverAddRequestDNSSecondaryNameserverResponseDNSUpdateRequestDNSZonesResponseMailAliasMailAliasByDomainMailAliasRemoveRequestMailAliasUpsertRequestMailAliasesResponseFormatMailUserMailUserAddPrivilegeRequestMailUserAddRequestMailUserByDomainMailUserPrivilegeMailUserRemovePrivilegeRequestMailUserRemoveRequestMailUserSetPasswordRequestMailUserStatusMailUsersResponseMailUsersResponseFormatMeAuthStatusMeResponseMfaDisableRequestMfaEnableRequestMfaStatusResponseMfaStatusResponseEnabledMfaMfaStatusResponseNewMfaSSLCSRGenerateRequestSSLCertificateInstallRequestSSLCertificatesProvisionResponseSSLCertificatesProvisionResponseRequestsSSLStatusSSLStatusResponseSSLStatusTypeStatusEntryStatusEntryExtraStatusEntryTypeSystemBackupConfigResponseSystemBackupConfigUpdateRequestSystemBackupStatusSystemBackupStatusResponseSystemPrivacyStatusSystemPrivacyUpdateRequestSystemStatusResponseWebDomainDocumentation For AuthorizationbasicAuthType: HTTP basic authentication