Skip to main content

Python wrapper for the YourSuper API

Project description

PythonYourSuperAPI

Python wrapper for the Australian Taxation Office YourSuper API

Installation

pip install YourSuperAPI

Available Options

amountRange (default=All)

Indicate how many results to return accepts integer between 1 and 9999 or array of two values to indicate range to return.

age (default=0)

Positive integer less than 100 to set account holder age.

balance (default=50000)

Positive Integer or Float value to set account balance, used to determine fees for each product.

private (default=False)

Boolean value to determine if private super funds will be returned.

performance (default=0)

Integer value to determine what performance tested super funds will be returned.

  • 0 (return all super funds)
  • 1 (return only super funds assessed to meet benchmark)
  • 2 (return only super funds assessed to fail benchmark)
  • 3 (return only super funds not assessed)

Examples

Fetch all products

from YourSuperAPI import YourSuperAPI

data = YourSuperAPI.get_data()

print(data)

Fetch first 5 products

from YourSuperAPI import YourSuperAPI

data = YourSuperAPI.get_data(amountRange=5)

print(data)

Fetch 10th - 20th products

from YourSuperAPI import YourSuperAPI

data = YourSuperAPI.get_data(amountRange=[10,20])

print(data)

Fetch with custom account balance ($1000.56)

from YourSuperAPI import YourSuperAPI

data = YourSuperAPI.get_data(balance=1000.56)

print(data)

Fetch with custom account holder age (42 years)

from YourSuperAPI import YourSuperAPI

data = YourSuperAPI.get_data(age=42)

print(data)

Fetch without private funds

from YourSuperAPI import YourSuperAPI

data = YourSuperAPI.get_data(private=True)

print(data)

Fetch underperforming funds

from YourSuperAPI import YourSuperAPI

data = YourSuperAPI.get_data(performance=2)

print(data)

Advanced Examples

Print 7 year net returns for public funds with $200,000 balance and 50 year old account holder

from YourSuperAPI import YourSuperAPI

data = YourSuperAPI.get_data(private=True, age=50, balance=200000)

for superfund in data:
    print(superfund["superannuationProviderProductName"])
    for subproduct in superfund["subProduct"]:
        print(subproduct["fundNetReturnLastSevenYearsPercentageNumber"])

Data Structure

The API returns a Python list of super funds, the structure of each of these funds follows:

{
  'performanceRatingCode': 'Performing', 
  'superannuationProviderDetailFundName': 'QSuper', 
  'superannuationProviderProductName': 'QSuper Lifetime', 
  'subProduct': [{
    'lifeCycleStageName': 'Focus 1 Group', 
    'fundNetReturnLastSevenYearsPercentageNumber': 7.98, 
    'fundNetReturnLastFiveYearsPercentageNumber': 7.37, 
    'fundNetReturnLastThreeYearsPercentageNumber': 8.2, 
    'privateFundIndicator': 'N', 
    'adminFeesDisclosedAmount': 80.0, 
    'riskLevelCode': 'Medium', 
    'internetURLAddress': 'https://qsuper.qld.gov.au/our-products/investment-options/lifetime', 
    'superannuationFundInvestmentStrategyTypeCode': 'Lifecycle', 
    'superannuationProductSubproductID': 724652609, 
    'investmentFeesDisclosedAmount': 195.0, 
    'totalFeesDisclosedAmount': 275.0
  }]
}

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

YourSuperAPI-0.0.3.tar.gz (3.9 kB view details)

Uploaded Source

Built Distribution

YourSuperAPI-0.0.3-py3-none-any.whl (4.4 kB view details)

Uploaded Python 3

File details

Details for the file YourSuperAPI-0.0.3.tar.gz.

File metadata

  • Download URL: YourSuperAPI-0.0.3.tar.gz
  • Upload date:
  • Size: 3.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.6.1 requests/2.26.0 setuptools/40.8.0 requests-toolbelt/0.9.1 tqdm/4.28.1 CPython/3.7.1

File hashes

Hashes for YourSuperAPI-0.0.3.tar.gz
Algorithm Hash digest
SHA256 21b55bb402f27cecce2ca5ca6fd3d6a0caaa6e6e48e761059b36dad117813992
MD5 54c845121cfaec51f8eee5bf1779d8e2
BLAKE2b-256 7acccf117086abd3d68e167de75d41d7e1a85a0ea6ecac73c9fa19f96a6fc8ce

See more details on using hashes here.

File details

Details for the file YourSuperAPI-0.0.3-py3-none-any.whl.

File metadata

  • Download URL: YourSuperAPI-0.0.3-py3-none-any.whl
  • Upload date:
  • Size: 4.4 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.6.1 requests/2.26.0 setuptools/40.8.0 requests-toolbelt/0.9.1 tqdm/4.28.1 CPython/3.7.1

File hashes

Hashes for YourSuperAPI-0.0.3-py3-none-any.whl
Algorithm Hash digest
SHA256 3745b25d3d72e27c5a8372dfa9b08f34c1109eeefc23543c7650d4ff11b8ad98
MD5 249e587cdae6bca80919b840b02ccf05
BLAKE2b-256 8ddab7756f9ace05c93b5d440a59e1c7df679471694bbe988d9ef5b995280a69

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page