Skip to content

Developers

Mostly about Wild Apricot API. Feel free to share examples of your code!

78 results found

  1. Authentication for the API call to observe the Contact's privacy settings

    We are using the API https://api.wildapricot.org/v2/accounts/\(id)/contacts to get the list of contacts.

    We use User login + password authentication for the API call.

    If we use an admin account for the API authentication we get all fields for each contact, even fields that the contact has marked as "No access" in privacy. If we use a regular user account for the authentication we get immediately an HTTP 403 unauthorized status to even run the query.

    So the question: how do we set up the authentication for this API call so that the query only returns contact fields that the contact…

    1 vote

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)

    We’ll send you updates on this idea

    0 comments  ·  API  ·  Admin →
    How important is this to you?

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)
  2. Date timezone?

    1. Date timezone - If I get a datetime back from an API call in JSON (e.g. an event start date) in which timezone is that date expressed? I was thinking it would be expressed in UTC but that does not seem to be the case. It appears to be expressed in my current timezone PDT. e.g. if my event in California (PDT) starts at 9:00 am PDT then does the event start time JSON string returned come back as 9:00 am or 4:00 pm? (i.e. expressed in the PDT or UTC time zone)

    The JSON date string in question has…

    1 vote

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)

    We’ll send you updates on this idea

    0 comments  ·  API  ·  Admin →
    How important is this to you?

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)
    Resolved  ·  Dmitry Smirnov responded

    API returns dates in ISO 8601 format. Here is an example:
    “2019-11-15T15:05:39.453-04:00”
    date: 2019-11-15
    time: 15:05:39.453
    UTC offcet: -04:00

    AI uses UTC offset of your organization’s timezone.

  3. export membership data

    I have been reading the doc but I don't see what API call I use to download a variety of member data. I need more than Membership Level.

    I want an API call like the Member List Export, where I can choose the fields.
    I want to export (for all members) member first,last,level,status, and one custom field we have in our database. Prefer output as CSV, but JSON would be fine.
    I need this via the API because I want to automate it to feed into a Access Validation system we have developed, not google docs or Excel, etc.
    I…

    1 vote

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)

    We’ll send you updates on this idea

    2 comments  ·  API  ·  Admin →
    How important is this to you?

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)
  4. Why am I getting 404 error when requesting token? (kotlin/android/retrofit)

    (TEMPLATE)
    POST /auth/token HTTP/1.1
    Host: oauth.wildapricot.org
    Authorization: Basic QVBJS0VZOm85c2U4N3Jnb2l5c29lcjk4MDcwOS0=
    Content-type: application/x-www-form-urlencoded

    granttype=clientcredentials&scope=auto

    (My Attempt)--------------------------------------------------------------------

    object WAApiCallService {
    private const val APIKEY = "xxxxxxxxxxxxxxxxxxxx"
    private const val BASE
    URL = "https://oauth.wildapricot.org"
    private val AUTH = "Basic" + Base64.encodeToString(APIKEY.toByteArray(), Base64.NOWRAP)
    private const val CONTENT_TYPE = "application/x-www-form-urlencoded"

    private var api:WAApiCall? = null
    
    private fun getWAApi(context: Context) : WAApiCall {
    
        if(api==null){
            val OkHttpClient = OkHttpClient.Builder()
            val logging = HttpLoggingInterceptor()
            logging.level = HttpLoggingInterceptor.Level.BODY
            if(BuildConfig.DEBUG){
                OkHttpClient.addInterceptor(logging)
            }
                    //define and add a cache
            val cacheSize = 5 * 1024 * 1024L // = 5mb cache
            val cache = Cache(context.cacheDir, cacheSize)
    1 vote

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)

    We’ll send you updates on this idea

    0 comments  ·  API  ·  Admin →
    How important is this to you?

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)
  5. Change Event AccessLevel from API

    Please provide a way to change Event AccessLevel from API. I clone/create events via programs using API and need to change AccessLevel to Public as final step to enable registration. Thanks!

    1 vote

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)

    We’ll send you updates on this idea

    0 comments  ·  API  ·  Admin →
    How important is this to you?

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)
  6. Get member first name, last name, email address from id

    I have tried unsuccessfully to get a user first name, last name, email address from the ID.
    Here is what I tried to get the last name:
    https://api.wildapricot.org/v2.1/accounts/12345/contacts?async=false&$filter=$async=false&?$select='Last%20Name'%$filter='Member ID' eq 11111111

    What am I doing wrong?
    Thanks,
    Jay

    1 vote

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)

    We’ll send you updates on this idea

    1 comment  ·  API  ·  Admin →
    How important is this to you?

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)
  7. GET /accounts/{accountId}/events

    The swagger docs do not really show how to add the parameters to the HTTP Get request (e.g., $filter). For example, how do I format the request to get all events that have the substring "XYZ" in a Tags field?
    Also what is the syntax of the "TextIndex, Supported operations: substringof." parameter? You have all these good parameters in the Swagger site, but no real examples of how to use the syntax. Are we supposed to guess? Help me out here please. Thanks.

    1 vote

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)

    We’ll send you updates on this idea

    1 comment  ·  API  ·  Admin →
    How important is this to you?

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)
  8. API and custom fields - how to reference them in $select or $filter

    Hi. According to some of the documentation it implies that I can use a custom fields' name to reference it. I can directly reference common fields as a $select parameter, but can only reference other fields using their custom-xxx tag, like this:

    '$select' => 'First name, Last name, Email, custom-8097667,
    custom-8097668, custom-8161502, custom-8097675, custom-8017535'

    The custom field tag does not seem to appear anywhere in Membership fields area of the WA database though so the only way I can find it out is by trawling through json data manually.

    Is there a better way to reference those fields, or to…

    1 vote

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)

    We’ll send you updates on this idea

    3 comments  ·  API  ·  Admin →
    How important is this to you?

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)
  9. Is it correct that users cannot get their membership data via API?

    I'm working with a tool called Cognito Forms that allow some fairly complex form functionality. One great feature is the ability to pass values to a form embedded on a Wild Apricot page.

    We are currently working on a feature where a member navigates to a member-only page for expense reimbursement. The page loads an embedded form and pre-fills most of the information.

    Right now, I am using the API to use the contacts/me call to load name and email, but I need the contact/{contact-ID} to get the address and phone.

    After getting the script completed and pre-populating the form…

    1 vote

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)

    We’ll send you updates on this idea

    2 comments  ·  API  ·  Admin →
    How important is this to you?

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)
  10. Swaggerhub returns 403 Forbidden on all requests to API

    Real simple: Using Swaggerhub to play with the API. I give it a valid API key, it is able to login/authenticate successfully, but the only function returning code 200 OK is default (/) ... when I try the /accounts function or any other function I get 403. Tried 2 different API keys..... with both read-only and admin level access but No matter what I do I get a 403 trying to test the API using the swaggerhub UI

    1 vote

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)

    We’ll send you updates on this idea

    2 comments  ·  API  ·  Admin →
    How important is this to you?

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)
    Resolved  ·  Dmitry Smirnov responded

    That typically occures if you don’t check “Auto” checkbox in the scopes list (swaggerhub does not allow to check it by default).

    So when oAuth service gets your response it creates oAuth token with almost no permissions. Technically it is totally valid situation, but such token is almost useless.

    So the solution is to check “Auto” checkbox in the list of scopes.

  11. Using API on MS Access 2016

    I extended the excel sample API V2 app to develop an attendance system for our club. For a number of reasons, we're working to move off of Excel and onto Access. The sample code from WA runs smoothly on Excel, but not on Access. The sample includes the following (in function GetOAuthToken)

    Dim httpClient as IXMLHTTPRequest
    Set httpClient = CreateObject("Msxml12.XMLHTTP.3.0")
    httpClient.Open "POST", url, False

    (where url = "https://oauth.wildapricot.org/auth/token")

    The client.open returns 'unauthorized'. I cannot find any documentation on the open method of the httpclient object. And I have no idea what extra authorization I need when working in…

    1 vote

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)

    We’ll send you updates on this idea

    Resolved  ·  3 comments  ·  API  ·  Admin →
    How important is this to you?

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)
  12. "The remote server returned an error: (403) forbidden."

    I am using the sample visual studio c# program you have provided (see attachment). The program is failing in trying to access https://api.wildapricot.org/v2. Version2 is failing with a 403 forbidden error message. Any suggestions how I could solve this issue?

    1 vote

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)

    We’ll send you updates on this idea

    0 comments  ·  API  ·  Admin →
    How important is this to you?

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)
  13. API calls to update contacts suddenly failing

    We have a Google Apps script that is used to update a custom contact field. This code has been working and unchanged for the past year, and has suddenly lost the ability to update contacts. Other API calls to get contacts, update event registrations, etc. are still working fine, but can't update any contact fields through the API. Attempts to do so result in an HTTP 500 error. We are still able to update contacts through the web interface.

    Relevant information pasted after the break.


    Error:
    [17-09-16 07:31:21:841 CDT] Exception: Request failed for https://api.wildapricot.org/v2/accounts/84576/Contacts/40772038 returned code 500. Truncated server response:…

    1 vote

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)

    We’ll send you updates on this idea

    2 comments  ·  API  ·  Admin →
    How important is this to you?

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)
    Resolved  ·  Team Mobile responded

    We fixed this issue, so it should work now.
    Feel free to reopen this topic if the issue remains.

  14. API Upload Pictures

    Hey WA Developers, I'm trying to work through some of the API documentation and I'm hung up on the "Uploading Pictures" documentation.
    https://help.wildapricot.com/display/DOC/Pictures+API+V2+call
    I've got a Google Script constructed to upload an image from Google Drive to my trial WA site and I can't get it to work! 400 response code. Anybody up for taking a look and pointing out what I am doing wrong? Thanks so much!

    1 vote

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)

    We’ll send you updates on this idea

    Resolved  ·  1 comment  ·  API  ·  Admin →
    How important is this to you?

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)
  15. Contacts/me Returns null

    Hi!
    Using some of the sample code from the GitHub repo I've created a few custom PHP pages for events on a third party site. I'm trying to make the registration functionality work.
    The problem that I'm running into is the Contacts/me API call returns null even with a user logged in. I'm using the format:
    {baseAPIaddress}/{version}/Accounts/{accountID}/Contacts/me

    I am able to run Contact/{ContactID} and get the relevant data back. Do anyone know what might cause this?

    Thanks, Jason.

    1 vote

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)

    We’ll send you updates on this idea

    1 comment  ·  API  ·  Admin →
    How important is this to you?

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)
    Resolved  ·  Team Mobile responded

    The problem was solved.
    Note that API key isn’t connected with any contact. So contacts/me will return null if you are not authenticated by login/password.

  16. api events

    I am having trouble adding a new event through the api. I get a 403 error. Here is my google script code if anybody would be so kind as to point out where I have messed up. :) Thanks so much.

    https://gist.github.com/portercar/945c29474fece0e208991ac27f724203

    1 vote

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)

    We’ll send you updates on this idea

    Resolved  ·  1 comment  ·  API  ·  Admin →
    How important is this to you?

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)
  17. fieldvalues contact api

    I have an interesting issue you can help me with. I am using the Contacts API and calling it from a Javascript call using the WA API wrapper for jQuery. I got this code from the WA developer forum and loaded it into the files section to call locally from the WA install (rather than from the original location).

    http://iarpreiki.org/resources/js/waPublicApi.js

    I am using the API to create a URL that I will pass to an external SaaS system, so I need to collect various contact/membership field data.

    The testing page is at

    http://iarpreiki.org/Print-Your-Membership-Certificate -- the top HTML widget is where…

    1 vote

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)

    We’ll send you updates on this idea

    Resolved  ·  4 comments  ·  API  ·  Admin →
    How important is this to you?

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)
  18. Profile last updated field differs in filter from value read in API ?

    Hi,
    we have a job that queries via the API searching with a filter on "Profile last updated". The query can return no results, it doesn't find any contacts changed since the last query run. However if we just iterate through the contacts and read the Profile last updated field it can be more recent shown in the API results than displayed in the WA web interface. It appears when reading via the API the "last login date" is used as the Profile last updated date if the last login is newer than the last profile update.

    Summary:
    Profile last…

    1 vote

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)

    We’ll send you updates on this idea

    0 comments  ·  API  ·  Admin →
    How important is this to you?

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)
    Resolved  ·  Team Mobile responded

    The date in API and in web interface are taken from the same field in database. I was not able to reproduce error you described. Probably it was an error, which is already fixed.

    Please let us know if you encounter any error like this.

  19. Setting a Password when creating a new contact/member

    Hi,

    I need to create a contact through the API through a 3rd party server. I have no problem creating a contact. However, when I set a password and try to login after I have created the contact, I get an error saying that I have the wrong login information.

    Secondly, when someone signs up they get an email with a password sent to them. Is this possible as well through the API? When I create a contact through the API I want to be able to send them the password in their email so they can login.

    1 vote

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)

    We’ll send you updates on this idea

    0 comments  ·  API  ·  Admin →
    How important is this to you?

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)
  20. I need to access the "group participation" data for the current user. Can anybody show me how to access the data?

    I need to access the "group participation" data for the current user. Can anybody show me how to access this data?

    1 vote

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)

    We’ll send you updates on this idea

    0 comments  ·  API  ·  Admin →
    How important is this to you?

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)
    Resolved  ·  Team Mobile responded

    Group participation data can be foubd in the fiels with name ‘Group participation’. For example:

    var contact = getContactById( 123 )
    for( i=0; i<contact.FieldValues.length;i++) {
    var record = contact.FieldValues[i];
    if( record.FieldName == ‘Group participation’)
    var groups = record.Value;
    }

  • Don't see your idea?

Developers

Categories

Feedback and Knowledge Base