function shareRecording(context) {
  var self = this;
  var token = context.getToken;
  var meta = context.getMeta;
  var recordingFile = context.recordingFile;

  var options = {
    method: 'POST',
    url: BASEURL + '/v1/recording',
    formData: {
      title: meta.title,
      description: meta.description,
      tags: meta.tags,
      platform: meta.platform,
      token: token,
      file: {
        value: di.fs.createReadStream(recordingFile),
        options: {
          filename: 'recording.yml',
          contentType: 'application/x-yaml',
        },
      },
    },
  };

  return di
    .axios(options)
    .then((response) => {
      // Internal server error
      if (response.status === 500) {
        throw new Error(response.data.errors.join('\n'));
      }

      // Invalid input
      if (response.status === 400) {
        throw new Error(response.data.errors.join('\n'));
      }

      // Invalid token
      if (response.status === 401) {
        di.utility.removeToken();
        self.jump('getToken');
        return;
      }

      // Unexpected error
      if (response.status !== 200) {
        throw new Error('Something went wrong, try again later');
      }

      // Resolve with the URL from the response body
      return response.data.url;
    })
    .catch((error) => {
      // Reject the promise with the error
      throw error;
    });
}
Upload the recording

- If the token is rejected
  - Delete the token
  - Jump into the getToken task

- Resolve with the url of the uploaded recording

@param  {Object}  context
@return {Promise}