Introduction

Integrate Upwork functionalities to your web-based or mobile apps

Upwork Developers Site offers you access to our web services
to build your own applications and to integrate our features and workflow
to your dashboards, websites and management systems.
Please read Terms of use prior to using the Upwork Public API.

Libraries

API Entry Point

https://www.upwork.com/api

For Reports resources:

https://www.upwork.com/gds

Getting Started

Preparation

Before you start using Upwork API, you need to register your application and obtain your client credentials
(a.k.a consumer key and consumer secret). To register, you just fill in basic information about your application and its intended use.

provide a clear description on what you are planning using our APIs for (this info is required when you apply for a key). Make sure you add a note stating if you are going to use your application internally or publicly, or for any other purposes.

agree to use the Upwork API in a manner that does not exceed a reasonable request volume. Our daily allowed limit is 40K requests.

refrain from using the Upwork logo, brand name, brand theme/colors and trademarked content in your application

Warning

Users who try registering a new application/key, but have a profile without a valid ID will be forced to go through the ID verification process.

Application Permissions

When you register a new application, you are asked to define a list of permissions to access
third-party resource data; we call them “Application Permissions”. You can later modify the application
permissions you request, but note that doing so makes all previously generated access tokens invalid.
You will also have to request authorization from resource owners again.

On the right-hand side you can see the examples of how to make API calls with the chosen library.

Additionally, you can find a list of libraries for the language of your choice
to help you with the OAuth mechanism here.
To start using most of these libraries, you just need to provide your client credentials and the necessary URLs.

Request structure

All API requests must be made over HTTPS. API requests made over plain HTTP will be redirected to their equivalent HTTPS.

Cross-domain requests

Getting domain data from a domain different from the REST servers can cause failures.
This is why we standardized our API for cross-domain requests. This makes it possible for you
to use standard jQuery functions with the callback parameter.

Note

You must add &callback=? and oauth_xxx parameters to all your cross-domain requests,
otherwise the API will not return standardized jQuery data. You can supply a ?callback parameter to any request
in order to enable JSON-P wrapping. This is useful for cross-domain AJAX requests.

Versioning

We version our API to support forward and backward compatibility.
This means that new implementations don’t affect applications which depend on our API.
The API version you target is defined the first time you make an API request. Every time we make backward-incompatible changes to the API,
we release a new version. To avoid affecting your applications, we don’t modify your version until you’re ready to upgrade.
Note that our versioning process is made at the resource level.

Our API supports three ways of requesting a version of the API (see options on the right-hand side).

Note

We also support locating the version number on the second sub-path (if needed due to framework requirements).
For example: /api/v1/auth/info.json

Three ways of specifying a version for the API call:

standard (recommended)
the version is located on the third subpath in the URL:

/api/auth/v1/info.json

via ``X-Upwork-Version`` header (has higher priority):

X-Upwork-Version: v1

via ``Accept`` header (has lower priority)

Accept: application/vnd.upwork.api-v1+json

Response format

Our API supports both XML and JSON response formats.
We suggest you append the format specifier (.json or .xml) to the request URI to explicitly select JSON or XML. Otherwise, the API may default to either format.
You can also use the Accept request-header, passing application/xml (RFC3023) or
application/json (RFC4627) to define the response format.

Response elements

All responses include at least two elements:

auth_user - Information about the user making the request

server_time - Server time, in UNIX timestamp format

Response properties are always one of the following data types:

integer

A positive or negative whole number

string

Unicode text

URL

A string that conforms to RFC 1738

timestamp

A date expressed as seconds elapsed since January 1st, 1970

Pagination

Many calls support pagination. Although details of pagination and ordering may differ
(see specific information for each resource in the API reference),
API calls that do support pagination mostly do so by using the page and paging parameters.
The format of these parameters is: $offset;$count, for example: page=20;10

The default values are 0;10. Count can be restricted to <= N, where N is the maximum page size, found in the parameter description.

Encoding

We use UTF-8 encoding. UTF-8 encodes each Unicode character as a variable number of 1 to 4 octets,
where the number of octets depends on the integer value assigned to the Unicode character.
It is an efficient encoding of Unicode documents that use mostly US-ASCII characters because
it represents each character in the range U+0000 through U+007F as a single octet.

UTF-8 is the default encoding for XML and since 2010, it has become the dominant character set on the Web.

Rate Limits

Rate limiting of the API is primarily considered on a per-IP basis. We allow you to make 40 requests per window per IP. We use 1min windows. When an application exceeds the rate limit for our API, we will return an HTTP 429 “Too Many Requests” response code. If your application gets rate limited, then it will be unblocked within a minute since the last request that got rate limited.

To avoid being rate limited, please use caching in your application. Store API responses in your application if you expect a lot of use. For example, don’t try to call the Upwork API on every page load. Instead, call the API infrequently and load the response into a local cache. When users hit your website load the cached version of the results.

Terminology

In order to use Upwork API, it is important to have a good understanding of the
underlying concepts of Upwork Platform.

Users, clients, freelancers

User

An Upwork account holder. A user can have multiple roles simultaneously: client,
freelancer, agency staffing manager, and so on. A user must be a single person
and account sharing is not allowed. Others can be added to your company or agency.

Freelancer

A person who can apply to jobs, work, and get paid by clients via Upwork. In API parameters and arguments, sometimes the terms
provider and contractor are used to mean freelancer. Those are legacy names for the term.

Client

A person who, as part of a company, can hire Upwork freelancers. In API parameters and arguments, sometimes the term
buyer is used to mean client- it’s a synonym.

Agency contractor

There are two types of agency contractors. Exclusive agency contractors can only work on behalf of the agency.
The agency controls all their earnings. They cannot control their rates.
Non-exclusive agency contractors can work for multiple agencies and/or independently.
An agency can only control their agency jobs. Agency contractors can access reports on their worked hours, but not their earnings reports.

Companies, teams, agencies

Company

A primary financial entity and organizational unit. Larger companies can request to be divided into multiple teams.

Team

A basic unit of organization. Members of the team can see each other and
work on common tasks. Most user permissions are also relative to the team.
At the beginning, each company has one dedicated team room, but others
can be added later.

Agency

Acts as intermediary between the client and the freelancer. The client still hires a specific person,
but the contract is paid to the agency. Agency size and staffing manager involvement varies widely.

Job postings, offers and contracts

Job posting

Description of the work to be done and the application guidelines for freelancers.

Offer

Proposal of contract terms as part of the hiring process. It can be initiated by the client
or the freelancer, but it must be agreed upon by both parties.

Contract

The terms and conditions that rule a particular job between a client and a freelancer. Legacy terms: engagement.

Fixed-price contract

Flat-rate contract or payment for milestones. It is not covered by the Upwork Guarantee.

Hourly contract

Contract billed per hour based on the Work diary registry. It is covered by the Upwork Guarantee.

Charge Amount

The amount of money that is deducted from the company’s financial account (Upwork fee included).

Amount

The amount of money that a freelancer or an agency receives as payment (Upwork fee not included).

Work diary

The Work diary acts as a visual time card. It is the basis for Upwork’s automated weekly billing system.
It shows clients hours worked and work-in-progress screenshots.

Roles and permissions

There are two kinds of permissions within the context of our API:

• Application Permission: a permission to access an API endpoint. It is also called “scope” or “Key Permission”.

• User permission: a permission to access content and it is specific to the user and context of the call (team, company).

Permissions define what a user can do in the context of a given team or a company.
All permissions are relative to the team room, except for owner, which is relative to the company.
In order to get certain permission on the API, you’re required to have specific permissions on the UI.
The following diagrams explain how permissions returned by the API are connected to the UI team roles.

The above mapping applies to cases where the user is assigned only one role. When a user is assigned
multiple roles, only one role will be returned with the following order of precedence:
admin, manager, recruiter and member.

On the other hand, the API can return multiple permissions. In this case, the result is the combination of
all of them. For example, if a user is full admin and full hiring manager, the following permissions
are returned: manage_finance, manage_employment, manage_recruiting...

The following table provides further details on the different roles.

Admin

Finance only: Can manage payment methods, view financial reports, and make deposits and withdrawals.
Finance privileges are company-wide, even when Teams are in use.

Full: In addition to finance privileges, can invite or remove team members, manage members
permissions, and edit company information.

Self Only: Can log time and view their own Work Diary. (Only applicable to freelancers with active contracts).

All: Can log time (with an active contract) and view Work Diaries and hours-only reports for all team members.

Can Chat With

No One: Can only see and respond to team members who initiate messaging.

Team Members: Can see and chat with everyone on the team.

Company Members: Can see and chat with everyone in the company, across all teams.

Contact Person

Main point of contact responsible for the freelancer’s contract. By default this is the person
who hired the freelancer, but you can set it to be anyone on your team who has a Hiring permission “Full”.

Authentication

To make API requests, you need to authenticate to Upwork API. Currently, we support OAuth 1.0 authentication.
All API requests MUST be signed following the RFC 5849 specification.

OAuth 1.0

The OAuth protocol enables websites or applications (clients) to access protected resources
from a web service (server) via an API, without requiring resource owners to disclose
their service provider credentials to the clients.
For more information on the OAuth workflow process visit
Beginner’s Guide to OAuth
and the OAuth 1.0 Guide.

Client credentials

For each application you develop, you need to obtain new client credentials. These include a client identifier
and a client shared-secret. You can request these credentials at https://www.upwork.com/services/api/apply
while logged into your Upwork account. You will receive a public and a private key for each client identifier
and client shared-secret you request.

Upwork OAuth 1.0 workflow

At a basic level, the OAuth 1.0 authentication process involves the following steps:

EXAMPLE REQUEST

There’s no public method for getting request token
in ruby-upwork, request token is retrieved
during invocation of the authorization (see below).
You can do it manually using the oAuth library if necessary.
There’s no public method for getting request token
in java-upwork, request token is retrieved
during invocation of the authorization (see below).
You can do it manually using the oAuth library if necessary.
There’s no public method for getting request token
in node-upwork, request token is retrieved
during invocation of the authorization (see below).
You can do it manually using the oAuth library if necessary.
There’s no public method for getting request token
in perl-upwork, request token is retrieved
during invocation of the authorization (see below).
You can do it manually using the oAuth library if necessary.
There’s no public method for getting request token
in golang-upwork, request token is retrieved
during invocation of the authorization (see below).
You can do it manually using the oAuth library if necessary.

Authorize and get verifier

Upwork server needs to request authorization from the resource owner to grant you access to the required data.
To do so, you need to redirect the resource owner to Upwork server’s authentication endpoint.

Returns

If the authorization is successful, this call returns a verifier. You can also
check for the X-Upwork-Oauth-Verifier header in the response.

If the resource owner is not currently logged in to Upwork, he/she is asked to do so at
www.upwork.com/login?redir=https://www.upwork.com/services/api/auth....

• If the resource owner has not authorized your (web server) application,
Upwork asks the resource owner if he/she wishes to do so.

• If your application is authorized, the resource owner is redirected to your (web server) application using
the callback URL provided with the request, or, if empty, to the one registered for the client identifier used.
The callback URL will have the following query parameters appended: ?oauth_token=...&oauth_verifier=....
For desktop applications, there’s no callback triggered. Instead, the verifier is shown to the resource owner in the browser window.

EXAMPLE REQUEST

get_authorize_url() method implicitly checks for the presence
of request tokens, and obtains them if necessary, so
you can omit calling get_request_token() manually and
just call get_authorize_url() to get a verifier.

In desktop application flow, just copy the verifier manually from the browser.

In web application flow make a GET request to the
generated authorization URL. Your registered callback
URL is triggered and verifier is passed
as oauth_verifier parameter.

importupworkimportrequestsclient=upwork.Client(public_key,secret_key,**credentials)authorize_url=client.auth.get_authorize_url()# Invoke the authorize urlrequests.get(authorize_url)# Or in the desktop flowverifier=raw_input('Please enter the verification code you get ''following this link:\n{0}\n\n> '.format(client.auth.get_authorize_url()))

EXAMPLE REQUEST

importupworkclient=upwork.Client(public_key,secret_key,**credentials)verifier=raw_input('Please enter the verification code you get ''following this link:\n{0}\n\n> '.format(client.auth.get_authorize_url()))access_token,access_token_secret=client.auth.get_access_token(verifier)

$client = new \Upwork\API\Client($config);$client->auth();

require'upwork/api'config=Upwork::Api::Config.new({'consumer_key'=>'','consumer_secret'=>'',})# setup clientclient=Upwork::Api::Client.new(config)authz_url=client.get_authorization_urlputs"Visit the authorization url and enter the oauth_verifier for further authorization:"putsauthz_urlverifier=gets.stripaccess_token=client.get_access_token(verifier)

Troubleshooting authentication issues

Authentication errors are the most common issues received by our Support team. Here are some troubleshooting tips
you may want to try to solve frequent authentication issues and start using our API.

• Most OAuth signing issues are caused by an invalid format in the signature base string.

• If you use a header-based OAuth request, make sure that the HTTP authorization header is being properly
setup and formatted according to the specific language you use. Remember that you SHOULD NOT repeat
any of the oauth_* parameters in the POST body or URL of the request you are making.
Parameters that begin with oauth_* SHOULD NOT be part of the POST body or query string.

• Don’t include unnecessary oauth_* parameters in the request.

• Use auth in all REST API methods that support it. All Upwork REST API methods require authentication
and using auth ensures that the requests are evaluated within the context of your current user.

• Use valid endpoints.

• Make sure you are using the appropriate HTTP request method.
Most calls to the Upwork API use POST or GET methods.

• If you use an OAuth library, make sure you select a well-supported one.

• Try making the request in another OAuth library or tool. Comparing successful and failed requests
will help you identify what might be going wrong.

• Learn how to override the oauth_timestamp and oauth_nonce values in your OAuth library.
Use this capability to replay signature generation scenarios for comparative analysis.

• oauth_token and oauth_token_secret strings change when a user’s access moves between permission levels,
or if a user denies your application access and then re-grants access.
Never assume that the strings will remain constant.

The following are the most frequent authentication errors you may come across:

400 - Bad request

The request could not be understood by the server due to malformed syntax.

Suggestion: Review the error message and make the necessary modifications before retrying.
You should not repeat the request without modifications.

• Can’t verify request, missing oauth_consumer_key or oauth_token.

• Can’t verify request signature, missing parameter.

• None of the signing methods is supported.

• Unsupported signature method.

• Expected OAuth version.

• Unsupported characters in host name.

• Unsupported scheme type, expected Timestamp is out of sequence.

401 - Unauthorized

User authentication is required and has failed or has not yet been provided.

Suggestion: Check the procedure for signature calculation.

• Verification of signature failed.

403 - Forbidden

The server understood the request, but is refusing to fulfill it.

Suggestion: Review the error message and make the necessary modifications before retrying.
You should not repeat the request without modifications.

• Duplicate timestamp/nonce combination, possible replay attack.

• The consumer_key and token combination does not exist or is not enabled.

User Permissions

This section explains how permissions returned by the API are connected to team roles.

Below you can find the details and requirements for the API.

Returns

While permission and role information is contained in the permission field, this API returns a complete list of a team information for each team that the authorized user has access to. It is also important to consider that a user may have multiple roles within a team.

For example, a user who has full manager permissions within a team returns the following fields:

Get freelancer profile by key

Returns

There is a lot of information returned by this call and the best way to see what it actually means is by pulling data from a few providers and match up the fields. Most of the response fields are human readable. Here is some additional info that should help understand this response:

dev_profile_access

The status of the freelancer’s profile (public or private).

skill

Describes a skill that the freelancer has listed in his/her profile.

tsexam

Describes a test that the freelancer has taken and made public.

dev_score

Describes feedback that the freelancer has received after a job has been completed (or just closed).

dev_recent_rank_percentile

The freelancer’s rank at Upwork based on data from the last 90 days.

dev_active_interviews

The number of active interviews the freelancer is engaged in at the moment.

dev_total_hours

The total hours worked on Upwork by the freelancer.

experience

Describes the freelancer’s experience as listed in his/her profile under the Experience section.

assignment

Describes past assignments that are publicly viewable.

skill, skl_level

A skill level for the current freelancer. Values can be one of the following: Familiar, Good, VeryGood,
Proficient, Expert.

dev_ic, affiliated

Both these metrics return the same data. They were added at different times and both of them are kept for backward compatibility purposes.

Jobs

This section describes API resources to manage jobs and job-related activities. You can
use these resources to search for jobs, post new jobs, list posted jobs, update jobs and delete them.
You can also invite freelancers to a job interview.

Search for jobs

Returns

This resource allows third-party applications to search for public jobs on Upwork. The search parameters mirror the options available on the site.

EXAMPLE RESPONSE

Get job profile

Returns

This resource returns an exhaustive list of attributes about the job. We recommend to pull data for a few freelancers and match up the fields to understand the meaning of the fields. Note that most of the response fields are human readable.

EXAMPLE RESPONSE

{'amount':'5','assignment_info':'','assignments':{'assignment':[{'as_ciphertext':'~abcdf1234567','as_ciphertext_opening_recno':'~abcdf1234549353a08','as_engagement_title':'API test job','as_from':'02/2014','as_job_type':'Fixed','as_opening_title':'API test job','as_rate':'$0.00','as_status':'Active','as_to':'Present','as_total_charge':'0','as_total_hours':'0'},{'as_ciphertext':'~abcdf1234567','as_ciphertext_opening_recno':'~abcdf123454e8f073e','as_engagement_title':'Testing an API','as_from':'10/2013','as_job_type':'Fixed','as_opening_title':'Test create job via API','as_rate':'$0.00','as_status':'Closed','as_to':'10/2013','as_total_charge':'1.11','as_total_hours':'0','feedback':{'comment':'Test Company is a very good client, clean specs and nice to communicate.','comment_is_public':'1','score':'5.00','scores':{'score':[{'description':'competency and skills for the job, understanding of task complexities','label':'Skills','score':'5'},{'description':'quality of specifications/instructions','label':'Quality','score':'5'},{'description':'online presence on a consistent schedule','label':'Availability','score':'5'},{'description':'understanding of complexities and trade-offs','label':'Deadlines','score':'5'},{'description':'communication skills and responsiveness, feedback and guidance','label':'Communication','score':'5'},{'description':'cooperation and flexibility, open to suggestions for improvement','label':'Cooperation','score':'5'}]}}}]},'buyer':{'op_adjusted_score':'5','op_city':'Bangkok','op_contract_date':'August 25, 2013','op_country':'Thailand','op_timezone':'UTC-08:00 Pacific Time (US & Canada); Los Angeles','op_tot_asgs':'2','op_tot_charge':'1.11','op_tot_fp_asgs':'2','op_tot_hours':'0','op_tot_jobs_filled':'2','op_tot_jobs_open':'0','op_tot_jobs_posted':'5'},'candidates':'','ciphertext':'~abcdf1234542a395a4','engagement_weeks':'','interviewees_total_active':'0','job_category_level_one':'Web, Mobile & Software Dev','job_category_level_two':'Web Development','job_type':'Fixed','op_attached_doc':'','op_cny_upm_verified':'1','op_contractor_tier':'','op_ctime':'1377423220000','op_description':'Will be discussed.','op_engagement':'Full-time - 30+ hrs/week','op_high_hourly_rate_all':'0','op_low_hourly_rate_all':'0','op_other_jobs':'','op_pref_english_skill':'0','op_pref_fb_score':'0','op_pref_has_portfolio':'0','op_pref_hourly_rate_max':'','op_pref_hourly_rate_min':'','op_pref_location':'','op_pref_odesk_hours':'0','op_required_skills':'','op_title':'Test Upwork API','op_tot_cand':'0','op_tot_feedback':'1','op_pref_group_id':'somegroup','op_pref_group_name':'Super group','op_pref_group_logo':'http://...','ui_opening_status':'Closed'}

EXAMPLE RESPONSE

Get company

Returns

This resource returns the details of the referenced company. If a user does not have access to the company, the resource returns a 403 error. This resource does not return the list of teams within the company.

The level of the user’s activity; on a scale of 0 (low) to 10 (high).The app logs the activity level by counting the number of mouse clicks, scroll actions, and keystrokes made by the freelancer. See the field “task” for information on the task the freelancer is working on.

screenshot_url

The URL of the screenshot for this entry.

mouse_events_count

The number of mouse events associated with this entry.

company_id

The Upwork ID of the company associated with the user in this entry.

timezone

The time zone of the entry.

uid

The user ID of the user.

keyboard_events_count

The number of keyboard events associated with this entry.

memo

The memo associated with the current entry.

active_window_title

The name of the active window at the user’s device when the entry was made.

computer_name

The name of the user’s device during the current entry.

screenshot_img_thmb

URL of a thumbnail of the current screenshot.

user_id

The user’s Upwork ID.

client_version

The client version used.

snapshot_api

The resource used for the snapshot.

task

Activity (a.k.a task) the freelancer is working on. Activities are client-defined categories or labels that a freelancer can choose when tracking time to enable organized reporting to the client. See the field “activity” for information on the level of activity.

The level of the user’s activity; on a scale of 0 (low) to 10 (high).The app logs the activity level by counting the number of mouse clicks, scroll actions, and keystrokes made by the freelancer. See the field “task” for information on the task the freelancer is working on.

screenshot_url

The URL of the screenshot for this entry.

mouse_events_count

The number of mouse events associated with this entry.

company_id

The Upwork ID of the company associated with the user in this entry.

timezone

The time zone of the entry.

uid

The user ID of the user.

keyboard_events_count

The number of keyboard events associated with this entry.

memo

The memo associated with the current entry.

active_window_title

The name of the active window at the user’s device when the entry was made.

computer_name

The name of the user’s device during the current entry.

screenshot_img_thmb

URL of a thumbnail of the current screenshot.

user_id

The user’s Upwork ID.

client_version

The client version used.

snapshot_api

The resource used for the snapshot.

task

Activity (a.k.a task) the freelancer is working on. Activities are client-defined categories or labels that a freelancer can choose when tracking time to enable organized reporting to the client. See the field “activity” for information on the level of activity.

contracts=Upwork::Api::Routers::Hr::Contracts.new(client)params={'message'=>'Suspended the contract'}contracts.suspend_contract(12345,params)

importcom.Upwork.api.Routers.Hr.Contracts;importjava.util.HashMap;Contractscontracts=newContracts(client);HashMap<String,String>params=newHashMap<String,String>();params.put("message","Suspended the contract");contracts.suspendContract("12345",params);

varContracts=require('upwork-api/lib/routers/hr/contracts.js').Contracts;varcontracts=newContracts(api);varreference='12345';varparams={'message':'Suspended the contract'};contracts.suspendContract(reference,params,function(error,data){console.log(data);});

my$contracts=Upwork::Api::Routers::Hr::Contracts->new($api);my%params={'message'=>'Suspended the contract'};$contracts->suspend_contract(12345,%params);

import(contractsUpwork"github.com/upwork/golang-upwork/api/routers/hr/contracts")contracts:=contractsUpwork.New(client)params:=make(map[string]string)params["message"]="Suspended the contract"contracts.SuspendContract("12345",params)

contracts=Upwork::Api::Routers::Hr::Contracts.new(client)params={'message'=>'Restarting the contract'}contracts.restart_contract(12345,params)

importcom.Upwork.api.Routers.Hr.Contracts;importjava.util.HashMap;Contractscontracts=newContracts(client);HashMap<String,String>params=newHashMap<String,String>();params.put("message","Restarting the contract");contracts.restartContract("12345",params);

varContracts=require('upwork-api/lib/routers/hr/contracts.js').Contracts;varcontracts=newContracts(api);varreference='12345';varparams={'message':'Restarting the contract'};contracts.restartContract(reference,params,function(error,data){console.log(data);});

my$contracts=Upwork::Api::Routers::Hr::Contracts->new($api);my%params={'message'=>'Restarting the contract'};$contracts->restart_contract(12345,%params);

import(contractsUpwork"github.com/upwork/golang-upwork/api/routers/hr/contracts")contracts:=contractsUpwork.New(client)params:=make(map[string]string)params["message"]="Restarting the contract"contracts.RestartContract("12345",params)

EXAMPLE RESPONSE

Milestones

Fixed-priced jobs allow splitting the contract into milestones
(significant points in the process of the work to be done).
Then, clients are charged when a milestone is created, the money is placed into “escrow”,
and released when the milestone is completed.

As a client, once you’ve hired a freelancer on a fixed-price contract, you can start
adding milestones.
Milestones are created in a “not funded” status.
You can activate
one milestone at a time.
Also note, that only milestones with a “not funded” status can be edited
or deleted.
Once the milestone is active it can only be closed by approving it
or ending the contract, which cancels it.

As a freelancer you can
submit work to a milestone.
This work submission can be either
approved
or rejected
by a client.
If the submission is approved,
the milestone proceeds to a “paid” status
and funds in escrow are released to the freelancer.

milestones=Upwork::Api::Routers::Hr::Milestones.new(client)milestone_id=1234params={'message'=>'Activating second milestone'}milestones.activate(milestone_id,params)

importcom.Upwork.api.Routers.Hr.Milestones;importjava.util.HashMap;Milestonesmilestones=newMilestones(client);StringmilestoneId="1234";HashMap<String,String>params=newHashMap<String,String>();params.put("message","Activating second milestone");milestones.activate(milestoneId,params);

varMilestones=require('upwork-api/lib/routers/hr/milestones.js').Milestones;varmilestones=newMilestones(api);varmilestoneId=1234;varparams={'message':'Activating second milestone'};milestones.activate(milestoneId,params,function(error,data){console.log(data);});

mymilestones=Upwork::Api::Routers::Hr::Milestones->new($api);mymilestone_id=1234;my%params={'message'=>'Activating second milestone'};$milestones->activate($milestone_id,%params);

import(milestonesUpwork"github.com/upwork/golang-upwork/api/routers/hr/milestones")milestones:=milestonesUpwork.New(client)milestoneId="1234";params:=make(map[string]string)params["message"]="Activating second milestone"milestones.Activate(milestoneId,params)

submissions=Upwork::Api::Routers::Hr::Submissions.new(client)submission_id=1234params={'note2contractor'=>'Note to freelancer'}submissions.reject(submission_id,params)

importcom.Upwork.api.Routers.Hr.Submissions;importjava.util.HashMap;Submissionssubmissions=newSubmissions(client);StringsubmissionId="1234";HashMap<String,String>params=newHashMap<String,String>();params.put("note2contractor","Note to freelancer");submissions.reject(submissionId,params);

varSubmissions=require('upwork-api/lib/routers/hr/submissions.js').Submissions;varsubmissions=newSubmissions(api);varsubmissionId=1234;varparams={'note2contractor':'Note to freelancer'};submissions.reject(submissionId,params,function(error,data){console.log(data);});

my$submissions=Upwork::Api::Routers::Hr::Submissions->new($api);my$submission_id=1234;my%params={'note2contractor'=>'Note to freelancer'};$submissions->reject($submission_id,%params);

import(submissionsUpwork"github.com/upwork/golang-upwork/api/routers/hr/submissions")submissions:=submissionsUpwork.New(client)submissionId="1234";params:=make(map[string]string)params["note2contractor"]="Note to freelancer"submissions.Reject(submissionId,params)

DEFINITION

EXAMPLE RESPONSE

Create a new room

All parameters must be wrapped into json object, e.g. {“roomName”:”Group Project”,”roomType”:”GROUP”, ... }, and sent as a separate parameter called room.

Returns

Returns HTTP code 201. Includes a link to the room in the Location header and the room ID in the response body, if creation was successful.

DEFINITION

Send a message to a room

Warning

All parameters must be wrapped into json object, e.g. {“message”: “a message”, ...}, and sent as a separate parameter called story.

Returns

Returns HTTP code 201.

DEFINITION

Update a room settings

Warning

All parameters must be wrapped into json object, e.g. {“isFavorite”: “true”}, and sent as a separate parameter called update_request.

Returns

Returns HTTP code 200.

DEFINITION

Archive or rename a room

Warning

All parameters must be wrapped into json object, e.g. {“isReadOnly”: “true”}, and sent as a separate parameter called metadata.

Returns

Returns HTTP code 200.

DEFINITION

Activities

This section describes a set of resources that allow you to manage
activities – Upwork task management system. The term “activity”
is used with the meaning of “task” throughout the following reference documentation.

Activities API resources allow you to assign specific activities to freelancers.
These resources require authentication and require the user to be a member of the referenced company or team, and have hiring permissions.

EXAMPLE RESPONSE

Snapshots

This section describes resources that allow you to get activity snapshots from a user account, in a company’s team, at specific points in time. You can also update and delete snapshots. These resources can only be used with the teams the user has access to. An error will be returned if the currently authorized user does not have access to the teammate details being requested.

Get snapshot

Returns

Details on the response:

snapshot

Snapshot detail container.

status

Status of the snapshot. Can be: LOGIN, NORMAL, PRIVATE, EXIT

time

The GMT Unix timestamp when the snapshot was taken

billing_status

The billing status of the snapshot: non-billed.disconnected, billed.disconnected, billed.connected

Below you will find the detailed description of what fields are available for constructing GDS queries.

Note

Please note that you may get a report timeout if you select a large time period.

Time reports data source fields

Here are the fields that are applicable for time reports queries:

Field Name

Description

GDS Type

worked_on

The date when work was performed by the freelancer.

date

week_worked_on

Monday’s date corresponding to the week when the worked_on occurs.

date

month_worked_on

The month, in number, for the date
in the worked_on field.

date

year_worked_on

The year in the date that appears in the Start Date field.

date

provider_id

The ID of freelancer.

string

provider_name

The freelancer’s name.

string

team_id

The ID of team billed.

string

team_name

The name of team billed.

string

assignment_team_id

The ID of the hiring team in the assignment.

string

assignment_name

The opening title of the assignment.

string

agency_id

The team ID of the agency.

string

agency_name

The name of the agency.

string

company_id

The team ID of rollup assignment_team_id.

string

agency_company_id

The agency ID of rollup agency_id.

string

task

The activities which the freelancer worked on.

string

memo

The memos logged by the freelancer during work.

string

hours

The total hours worked by the freelancer

during the date of worked_on.

Supports aggregation

number

charges

The total amount charged to the client.

Supports aggregation

number

hours_online

The number of online hours in hours.

Supports aggregation

number

charges_online

The charges of work performed online.

Supports aggregation

number

hours_offline

The number of offline hours, in hours.

Supports aggregation

number

charges_offline

The charges of work performed offline.

Supports aggregation

number

Note

The format of GDS date type is [yyyy-mm-dd].

Aggregation Functions

Name

Description

Data Type

sum()

Sums all
the values
in the
columns for
a group

Numeric

Note

All fields that co-exist with an aggregated field will be implicitly grouped.

Language Clauses

Clause

Usage

select

Selects which fields from the time reports data source
table to return.

where

A condition to match rows.

group by

This clause is not supported but the same effect can be
achieved by applying an aggregation function to the
columns listed in the select clause. For instance,
applying sum() to one of the columns causes other
columns to be grouped implicitly.

order by

Sort rows in the return columns.

Select

Only the fields defined in the data source table can be selected.
If this clause is not specified, default fields of specific functions are returned.
However, select\* is not supported.

Fields with numeric type specified in the select clause can be applied
with the Aggregation function, if supported.