Skip to content

Latest commit

 

History

History
132 lines (96 loc) · 3.34 KB

V1LocationsApi.md

File metadata and controls

132 lines (96 loc) · 3.34 KB

Square.Connect.Api.V1LocationsApi

All URIs are relative to https://connect.squareup.com

Method HTTP request Description
ListLocations GET /v1/me/locations Provides details for a business's locations, including their IDs.
RetrieveBusiness GET /v1/me Get a business's information.

ListLocations

List ListLocations ()

Provides details for a business's locations, including their IDs.

Provides details for a business's locations, including their IDs.

Example

using System;
using System.Diagnostics;
using Square.Connect.Api;
using Square.Connect.Client;
using Square.Connect.Model;

namespace Example
{
    public class ListLocationsExample
    {
        public void main()
        {
            
            // Configure OAuth2 access token for authorization: oauth2
            Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN";

            var apiInstance = new V1LocationsApi();

            try
            {
                // Provides details for a business's locations, including their IDs.
                List<V1Merchant> result = apiInstance.ListLocations();
                Debug.WriteLine(result);
            }
            catch (Exception e)
            {
                Debug.Print("Exception when calling V1LocationsApi.ListLocations: " + e.Message );
            }
        }
    }
}

Parameters

This endpoint does not need any parameter.

Return type

List

Authorization

oauth2

HTTP request headers

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

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

RetrieveBusiness

V1Merchant RetrieveBusiness ()

Get a business's information.

Get a business's information.

Example

using System;
using System.Diagnostics;
using Square.Connect.Api;
using Square.Connect.Client;
using Square.Connect.Model;

namespace Example
{
    public class RetrieveBusinessExample
    {
        public void main()
        {
            
            // Configure OAuth2 access token for authorization: oauth2
            Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN";

            var apiInstance = new V1LocationsApi();

            try
            {
                // Get a business's information.
                V1Merchant result = apiInstance.RetrieveBusiness();
                Debug.WriteLine(result);
            }
            catch (Exception e)
            {
                Debug.Print("Exception when calling V1LocationsApi.RetrieveBusiness: " + e.Message );
            }
        }
    }
}

Parameters

This endpoint does not need any parameter.

Return type

V1Merchant

Authorization

oauth2

HTTP request headers

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

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