Skip to content

Latest commit

 

History

History
177 lines (125 loc) · 5.49 KB

PayeeLocationsApi.md

File metadata and controls

177 lines (125 loc) · 5.49 KB

ynab.PayeeLocationsApi

All URIs are relative to https://api.youneedabudget.com/v1

Method HTTP request Description
get_payee_location_by_id GET /budgets/{budget_id}/payee_locations/{payee_location_id} Single payee location
get_payee_locations GET /budgets/{budget_id}/payee_locations List payee locations
get_payee_locations_by_payee GET /budgets/{budget_id}/payees/{payee_id}/payee_locations List locations for a payee

get_payee_location_by_id

PayeeLocationResponse get_payee_location_by_id(budget_id, payee_location_id)

Single payee location

Returns a single payee location

Example

from __future__ import print_function
import time
import ynab
from ynab.rest import ApiException
from pprint import pprint

# Configure API key authorization: bearer
configuration = ynab.Configuration()
configuration.api_key['Authorization'] = 'YOUR_API_KEY'
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['Authorization'] = 'Bearer'

# create an instance of the API class
api_instance = ynab.PayeeLocationsApi(ynab.ApiClient(configuration))
budget_id = 'budget_id_example' # str | The ID of the Budget.
payee_location_id = 'payee_location_id_example' # str | ID of payee location

try:
    # Single payee location
    api_response = api_instance.get_payee_location_by_id(budget_id, payee_location_id)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling PayeeLocationsApi->get_payee_location_by_id: %s\n" % e)

Parameters

Name Type Description Notes
budget_id str The ID of the Budget.
payee_location_id str ID of payee location

Return type

PayeeLocationResponse

Authorization

bearer

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to README]

get_payee_locations

PayeeLocationsResponse get_payee_locations(budget_id)

List payee locations

Returns all payee locations

Example

from __future__ import print_function
import time
import ynab
from ynab.rest import ApiException
from pprint import pprint

# Configure API key authorization: bearer
configuration = ynab.Configuration()
configuration.api_key['Authorization'] = 'YOUR_API_KEY'
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['Authorization'] = 'Bearer'

# create an instance of the API class
api_instance = ynab.PayeeLocationsApi(ynab.ApiClient(configuration))
budget_id = 'budget_id_example' # str | The ID of the Budget.

try:
    # List payee locations
    api_response = api_instance.get_payee_locations(budget_id)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling PayeeLocationsApi->get_payee_locations: %s\n" % e)

Parameters

Name Type Description Notes
budget_id str The ID of the Budget.

Return type

PayeeLocationsResponse

Authorization

bearer

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to README]

get_payee_locations_by_payee

PayeeLocationsResponse get_payee_locations_by_payee(budget_id, payee_id)

List locations for a payee

Returns all payee locations for the specified payee

Example

from __future__ import print_function
import time
import ynab
from ynab.rest import ApiException
from pprint import pprint

# Configure API key authorization: bearer
configuration = ynab.Configuration()
configuration.api_key['Authorization'] = 'YOUR_API_KEY'
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['Authorization'] = 'Bearer'

# create an instance of the API class
api_instance = ynab.PayeeLocationsApi(ynab.ApiClient(configuration))
budget_id = 'budget_id_example' # str | The ID of the Budget.
payee_id = 'payee_id_example' # str | ID of payee

try:
    # List locations for a payee
    api_response = api_instance.get_payee_locations_by_payee(budget_id, payee_id)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling PayeeLocationsApi->get_payee_locations_by_payee: %s\n" % e)

Parameters

Name Type Description Notes
budget_id str The ID of the Budget.
payee_id str ID of payee

Return type

PayeeLocationsResponse

Authorization

bearer

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to README]