Module: AvaTax::Client::DistanceThresholds
- Defined in:
- lib/avatax/client/distancethresholds.rb
Instance Method Summary collapse
- 
  
    
      #create_distance_threshold(companyId, model)  ⇒ CompanyDistanceThresholdModel[] 
    
    
  
  
  
  
  
  
  
  
  
    Create one or more DistanceThreshold objects. 
- 
  
    
      #delete_distance_threshold(companyId, id)  ⇒ ErrorDetail[] 
    
    
  
  
  
  
  
  
  
  
  
    Delete a single DistanceThreshold object. 
- 
  
    
      #get_distance_threshold(companyId, id)  ⇒ Object 
    
    
  
  
  
  
  
  
  
  
  
    Retrieve a single DistanceThreshold. 
- 
  
    
      #list_distance_thresholds(companyId, options = {})  ⇒ FetchResult 
    
    
  
  
  
  
  
  
  
  
  
    Retrieve all DistanceThresholds for this company. 
- 
  
    
      #query_distance_thresholds(options = {})  ⇒ FetchResult 
    
    
  
  
  
  
  
  
  
  
  
    Retrieve all DistanceThreshold objects. 
- 
  
    
      #update_distance_threshold(companyId, id, model)  ⇒ Object 
    
    
  
  
  
  
  
  
  
  
  
    Update a DistanceThreshold object. 
Instance Method Details
#create_distance_threshold(companyId, model) ⇒ CompanyDistanceThresholdModel[]
Create one or more DistanceThreshold objects
Create one or more DistanceThreshold objects for this company.
A company-distance-threshold model indicates the distance between a company and the taxing borders of various countries. Distance thresholds are necessary to correctly calculate some value-added taxes.
Security Policies
- This API requires one of the following user roles: AccountAdmin, BatchServiceAdmin, CompanyAdmin, CSPAdmin, CSPTester, SiteAdmin, SSTAdmin, SystemAdmin, TechnicalSupportAdmin. Swagger Name: AvaTaxClient
| 21 22 | # File 'lib/avatax/client/distancethresholds.rb', line 21 def create_distance_threshold(companyId, model) path = "/api/v2/companies/#{companyId}/distancethresholds" post(path, model, {}, AvaTax::VERSION) end | 
#delete_distance_threshold(companyId, id) ⇒ ErrorDetail[]
Delete a single DistanceThreshold object
Marks the DistanceThreshold object identified by this URL as deleted.
A company-distance-threshold model indicates the distance between a company and the taxing borders of various countries. Distance thresholds are necessary to correctly calculate some value-added taxes.
Security Policies
- This API requires one of the following user roles: AccountAdmin, BatchServiceAdmin, CompanyAdmin, CSPAdmin, CSPTester, SiteAdmin, SSTAdmin, SystemAdmin, TechnicalSupportAdmin. Swagger Name: AvaTaxClient
| 39 40 | # File 'lib/avatax/client/distancethresholds.rb', line 39 def delete_distance_threshold(companyId, id) path = "/api/v2/companies/#{companyId}/distancethresholds/#{id}" delete(path, {}, AvaTax::VERSION) end | 
#get_distance_threshold(companyId, id) ⇒ Object
Retrieve a single DistanceThreshold
Retrieves a single DistanceThreshold object defined by this URL.
A company-distance-threshold model indicates the distance between a company and the taxing borders of various countries. Distance thresholds are necessary to correctly calculate some value-added taxes.
Security Policies
- This API requires one of the following user roles: AccountAdmin, AccountUser, BatchServiceAdmin, CompanyAdmin, CompanyUser, CSPAdmin, CSPTester, SiteAdmin, SSTAdmin, SystemAdmin, TechnicalSupportAdmin, TechnicalSupportUser, TreasuryAdmin, TreasuryUser. Swagger Name: AvaTaxClient
| 57 58 | # File 'lib/avatax/client/distancethresholds.rb', line 57 def get_distance_threshold(companyId, id) path = "/api/v2/companies/#{companyId}/distancethresholds/#{id}" get(path, {}, AvaTax::VERSION) end | 
#list_distance_thresholds(companyId, options = {}) ⇒ FetchResult
Retrieve all DistanceThresholds for this company.
Lists all DistanceThreshold objects that belong to this company.
A company-distance-threshold model indicates the distance between a company and the taxing borders of various countries. Distance thresholds are necessary to correctly calculate some value-added taxes.
Security Policies
- This API requires one of the following user roles: AccountAdmin, AccountUser, BatchServiceAdmin, CompanyAdmin, CompanyUser, CSPAdmin, CSPTester, SiteAdmin, SSTAdmin, SystemAdmin, TechnicalSupportAdmin, TechnicalSupportUser, TreasuryAdmin, TreasuryUser. Swagger Name: AvaTaxClient
| 79 80 | # File 'lib/avatax/client/distancethresholds.rb', line 79 def list_distance_thresholds(companyId, ={}) path = "/api/v2/companies/#{companyId}/distancethresholds" get(path, , AvaTax::VERSION) end | 
#query_distance_thresholds(options = {}) ⇒ FetchResult
Retrieve all DistanceThreshold objects
Lists all DistanceThreshold objects that belong to this account.
A company-distance-threshold model indicates the distance between a company and the taxing borders of various countries. Distance thresholds are necessary to correctly calculate some value-added taxes.
Search for specific objects using the criteria in the $filter parameter; full documentation is available on Filtering in REST .
Paginate your results using the $top, $skip, and $orderby parameters.
Security Policies
- This API requires one of the following user roles: AccountAdmin, AccountUser, BatchServiceAdmin, CompanyAdmin, CompanyUser, CSPAdmin, CSPTester, SiteAdmin, SSTAdmin, SystemAdmin, TechnicalSupportAdmin, TechnicalSupportUser, TreasuryAdmin, TreasuryUser. Swagger Name: AvaTaxClient
| 103 104 | # File 'lib/avatax/client/distancethresholds.rb', line 103 def query_distance_thresholds(={}) path = "/api/v2/distancethresholds" get(path, , AvaTax::VERSION) end | 
#update_distance_threshold(companyId, id, model) ⇒ Object
Update a DistanceThreshold object
Replace the existing DistanceThreshold object at this URL with an updated object.
A company-distance-threshold model indicates the distance between a company and the taxing borders of various countries. Distance thresholds are necessary to correctly calculate some value-added taxes.
All data from the existing object will be replaced with data in the object you PUT. To set a field's value to null, you may either set its value to null or omit that field from the object you post.
Security Policies
- This API requires one of the following user roles: AccountAdmin, BatchServiceAdmin, CompanyAdmin, CSPAdmin, CSPTester, SiteAdmin, SSTAdmin, SystemAdmin, TechnicalSupportAdmin. Swagger Name: AvaTaxClient
| 125 126 | # File 'lib/avatax/client/distancethresholds.rb', line 125 def update_distance_threshold(companyId, id, model) path = "/api/v2/companies/#{companyId}/distancethresholds/#{id}" put(path, model, {}, AvaTax::VERSION) end |