The contractors/my method is an Elance Developer API Contractors method that retrieves the list of all contractors who have open jobs with the currently authenticated employer.

Results are returned in fixed pages of 25 records each. By default, the first page of results is returned with an initial request; additional pages are requested by issuing subsequent requests on the same search with the page query string parameter. Results must be presented to end users in the same order as returned by the Search methods. Re-ordering the results is considered a violation of the Elance Developer API Terms of Service.

This method must be called using an HTTPS GET request. All responses are returned in the JSON format.

I. Preconditions

This method requires that the calling application has authenticated a user using the OAuth 2.0 protocol, as described on the Getting Started page.

II. Required URL Parameters

There are no required URL parameters for this method.

III. Optional Query String Parameters

Parameter Description
page The page number of results to return, numbered beginning from 1. The default is 1. If this number is greater than the number of total pages (as expressed in the response by totalPages), the response contains zero results.
rpp The number of results requested per page. The default is 20. If more than 25 are requested, only 25 results are included in the response.

IV. Response Data Description

The response data for this method is similar to the response for the workroom/bidId/contractors method, except that the following additional properties are included with the BidData object:

Property Name Data Type Description
contractEndDate string A date consist of a three-letter month, day and year in the format "Mon DD, YYYY" that specifies the day on which this job is expected to be finished, and the project marked as complete.
milestonesCount integer The number of project checkpoints or deliverables defined for this project.
milestonesCompleted integer The number of project checkpoints or deliverables that have been completed to date.

V. Request/Response Examples in JSON

1. Requesting a List of All Contractors for the Current User

A. Request

The following URL requests a list of all of the contractors who are associated with the currently logged in user.

 https://api.elance.com/api2/contractors/my?access_token=4eb1de8bf06b10210e000005|3828514|OJShVvvqedVk2a28BOO4fA

B. Response

{
   "data": {
      "totalResults": 2,
      "totalPages": 1,
      "page": 1,
      "numResults": 2,
      "agents": {
         "0": {
            "screenData": {
               "timestamp": 1329673281,
               "userId": "3828695",
               "userName": "Barnie S.",
               "companyName": "Barnie Stinson",
               "logoURL": "https://elance.com/media/images/4.0/no-photo-64x80.jpg",
               "numComments": 0,
               "bidCount": "1",
               "bidId": "28595322",
               "bidData": {
                  "bidId": "28595322",
                  "jobId": "28595318",
                  "jobName": "More PHP Programming for Online Payment Module",
                  "userType": "CLIENT",
                  "clientUserId": "3828514",
                  "clientUserName": "employer01",
                  "clientName": "employer01",
                  "clientImageURL": "https://elance.com/media/images/4.0/no-photo-64x80.jpg",
                  "clientCountry": "United States",
                  "clientCountryCode": "US",
                  "clientCity": "Seattle",
                  "providerUserId": "3828695",
                  "providerUserName": "contractor02",
                  "providerName": "Barnie Stinson",
                  "providerImageURL": "https://elance.com/media/images/4.0/no-photo-64x80.jpg",
                  "providerCountry": "United States",
                  "providerCountryCode": "US",
                  "providerCity": "Seattle",
                  "phase": "5",
                  "status": "Working",
                  "isHourly": false,
                  "isSponsored": true,
                  "isPreBid": false,
                  "bidAmount": "5479.45",
                  "hourlyRate": "0",
                  "hoursPerWeek": "0",
                  "duration": "",
                  "submissionDate": 1329368400,
                  "contractEndDate": "Apr 19, 2012",
                  "milestonesCount": 1,
                  "milestonesCompleted": 0
               },
               "date": "19-FEB-12",
               "displayTime": "12:41 pm",
               "screenIdx": 3
            },
            "isOnTracker": false,
            "hours": 0,
            "hoursToday": 0
         },
         "1": {
            "screenData": {
               "timestamp": 1329097816,
               "userId": "3828515",
               "userName": "Marshall E.",
               "companyName": "Marshall Ericksen",
               "logoURL": "https://elance.com/media/images/4.0/no-photo-64x80.jpg",
               "numComments": 0,
               "bidCount": "1",
               "bidId": "28593984",
               "bidData": {
                  "bidId": "28593984",
                  "jobId": "28593983",
                  "jobName": "PHP Programming for Payment Module",
                  "userType": "CLIENT",
                  "clientUserId": "3828514",
                  "clientUserName": "employer01",
                  "clientName": "employer01",
                  "clientImageURL": "https://elance.com/media/images/4.0/no-photo-64x80.jpg",
                  "clientCountry": "United States",
                  "clientCountryCode": "US",
                  "clientCity": "Seattle",
                  "providerUserId": "3828515",
                  "providerUserName": "contractor_01",
                  "providerName": "Marshall Ericksen",
                  "providerImageURL": "https://elance.com/media/images/4.0/no-photo-64x80.jpg",
                  "providerCountry": "United States",
                  "providerCountryCode": "US",
                  "providerCity": "Seattle",
                  "phase": "5",
                  "status": "Working",
                  "isHourly": false,
                  "isSponsored": true,
                  "isPreBid": false,
                  "bidAmount": "9315.07",
                  "hourlyRate": "0",
                  "hoursPerWeek": "0",
                  "duration": "",
                  "submissionDate": 1329022800,
                  "contractEndDate": "Mar 12, 2012",
                  "milestonesCount": 2,
                  "milestonesCompleted": 0
               },
               "date": "12-FEB-12",
               "displayTime": "8:50 pm",
               "screenIdx": 4
            },
            "isOnTracker": false,
            "hours": 0,
            "hoursToday": 0
         }
      },
      "showFilters": {
         "filter_jobs": false,
         "filter_status": true
      }
   }
}

VI. Error Codes

For a list of error codes that can be thrown by this method, see Common API Error Codes.