Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

  • Sometimes-Present Fields

    • agencyId: The ID of the agency searched for.

    • agencyName: The name of the agency searched for.

    • distanceKm: The straight-line distance between the Client’s household (if their address is available) and the Agency’s address, in kilometres

    • distanceMi: The straight-line distance between the Client’s household (if their address is available) and the Agency’s address, in miles

    • timeSlots: An array of Time Slot objects each of which has:

      • dateFormat: Provides the standard date format that the system uses.

      • availableDateTime: The start date and time of the appointment, based on the agency’s local timezone.

      • availableDate: Specifically the date part of the time slot.

      • availableTime: Specifically the time part of the time slot.

      • availableRange: Both the start and end date and time of the specific time slot.

      • availabilityCount: The number of spots available at this time slot. Note: in some cases this is null, and in other cases it is zero or negative. These are all valid responses in the context of the system (null means the appointment isn’t time-based, zero means there are no available slots left, and negative means it has been over-booked, which can happen if the appointment caseload is not enforced.)

      • availableTimeslot: Fine-grained details of the date and time for the time slot.

      • locationId: The Link2Feed ID of the agency where the time slot is available.

      • location: The name of the agency where the time slot is available.

      • postcodeEligibility: A true/false response for whether or not this client is eligible, based on a postcode restriction – if this option is not present, there is no postcode restriction to consider for this program.

      • streetAddress: The street address of the location where the time slot is available.

    • provisions: A collection of Provision options that are available with this visit.

...

Code Block
[
    {
        "agencyId": 8659,
        "agencyName": "Agency 01",
        "distanceKm": 614.0448277573528,
        "distanceMi": 381.5497667107546,
        "timeSlots": [
            {
                "dateFormat": "Y-m-d H:i",
                "availableDateTime": "2021-02-08 12:15",
                "availableDate": "2021-02-08",
                "availableTime": "12:15",
                "availableRange": {
                    "start": "2021-02-08 12:15",
                    "end": "2021-02-08 12:45"
                },
                "availabilityCount": 5,
                "availableTimeslot": {
                    "year": 2021,
                    "month": 2,
                    "day": 8,
                    "hour": 12,
                    "minute": 15,
                    "dayName": "Monday"
                },
                "locationId": 8659,
                "location": "Agency 01",
                "postcodeEligibility": true
            },
            {
                "dateFormat": "Y-m-d H:i",
                "availableDateTime": "2021-02-08 12:45",
                "availableDate": "2021-02-08",
                "availableTime": "12:45",
                "availableRange": {
                    "start": "2021-02-08 12:45",
                    "end": "2021-02-08 13:15"
                },
                "availabilityCount": 5,
                "availableTimeslot": {
                    "year": 2021,
                    "month": 2,
                    "day": 8,
                    "hour": 12,
                    "minute": 45,
                    "dayName": "Monday"
                },
                "locationId": 8659,
                "location": "Agency 01",
                "postcodeEligibility": true,
                "streetAddress": "1234 Main Ave, Detroit, Michigan, 48216, United States"
            },
            ...
        ],
        "provisions": [
            {
                "provisionName": "Sample Food",
                "provisionId": 1509,
                "provisionDisplay": "checkbox"
            },
            ...
        ]
    }
]

...

  • The response is a single Array of multiple Objects, each with the following fields:

    • dateFormat: Provides the standard date format that the system uses.

    • availableDateTime: The start date and time of the appointment, based on the agency’s local timezone.

    • availableDate: Specifically the date part of the time slot.

    • availableTime: Specifically the time part of the time slot.

    • availableRange: Both the start and end date and time of the specific time slot.

    • availabilityCount: The number of spots available at this time slot. Note: in some cases this is null, and in other cases it is zero or negative. These are all valid responses in the context of the system (null means the appointment isn’t time-based, zero means there are no available slots left, and negative means it has been over-booked, which can happen if the appointment caseload is not enforced.)

    • availableTimeslot: Fine-grained details of the date and time for the time slot.

    • distanceKm: The straight-line distance between the Client’s household (if their address is available) and the Agency’s address, in kilometres

    • distanceMi: The straight-line distance between the Client’s household (if their address is available) and the Agency’s address, in miles

    • locationId: The Link2Feed ID of the agency where the time slot is available.

    • location: The name of the agency where the time slot is available.

    • provisions: A collection of Provision options that are available with this visit.

    • postcodeEligibility: A true/false response for whether or not this client is eligible, based on a postcode restriction – if this option is not present, there is no postcode restriction to consider for this program.

    • programId: The ID of the Program that manages the given appointment time slot.

    • programName: The name of the Program that manages the given appointment time slot.

    • streetAddress: The street address of the location where the time slot is available.

Response Codes:

  • 200 - OK. Response payload includes the data types details.

  • 400 - Bad Request. Will respond with a message including details of the request field errors. For example: { "message": "agencyId field not supplied." }

  • 401 - Unauthorized. There was an issue with the request. Ensure that all required headers are accurate (X-API-Key, Authorization, Signed-Headers and Host).

  • 404 - Not Found. There are no available appointments during the time period of the search, for the agency in question.

  • 5XX - Server Error. Any 5XX error (500, 502, 503, 504) means a Link2Feed error has occurred. Please contact Link2Feed if this persists.

...

Code Block
[
    {
        "dateFormat": "Y-m-d H:i",
        "availableDateTime": "2021-02-08 12:15",
        "availableDate": "2021-02-08",
        "availableTime": "12:15",
        "availableRange": {
            "start": "2021-02-08 12:15",
            "end": "2021-02-08 12:45"
        },
        "availabilityCount": 5,
        "availableTimeslot": {
            "year": 2021,
            "month": 2,
            "day": 8,
            "hour": 12,
            "minute": 15,
            "dayName": "Monday"
        },
        "distanceKm": 614.0448277573528,
        "distanceMi": 381.5497667107546,
        "locationId": 8659,
        "location": "Agency 01",
        "provisions": [
            {
                "provisionName": "Sample Food",
                "provisionId": 1509,
                "provisionDisplay": "checkbox"
            },
            ...
        ],
        "postcodeEligibility": false,
        "programId": 4649,
        "programName": "TEFAP Visit",
        "streetAddress": "1234 Main Ave, Detroit, Michigan, 48216, United States"
    },
    ...
]

Book an Appointment for a Client

...