Software

How to Pause a Task in Runrun.it

Java

import javax.ws.rs.client.Client;
import javax.ws.rs.client.ClientBuilder;
import javax.ws.rs.client.Entity;

public class RunrunitSample {

  public static void main(String[] args) {
    Client client = ClientBuilder.newClient();

    client.target("https://secure.runrun.it/api/v1.0/tasks/sampleTask/pause").request().header("App-Key", ...).header("User-Token", ...).post(Entity.json(""));
    
    client.close();
  }

}

Go

package runrunitsample

import "gopkg.in/resty.v1"

func main() {
  resty.R().SetHeader("Content-Type", "application/json").SetHeader("App-Key", ...).SetHeader("User-Token", ...).Post("https://secure.runrun.it/api/v1.0/tasks/sampleTask/pause")
}

Node.js

var https = require('https');

var req = https.post({ headers: { 'app-key': ..., 'user-token': ... }, hostname: 'secure.runrun.it', method: 'POST', path: '/api/v1.0/tasks/sampleTask/pause' });

req.end();

Python

import requests

requests.post('https://secure.runrun.it/api/v1.0/tasks/sampleTask/pause', headers = { 'App-Key': ..., 'User-Token': ... })

Ruby

require 'rest-client'

RestClient.post 'https://secure.runrun.it/api/v1.0/tasks/sampleTask/pause', :app_key => ..., :user_token => ...

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

This site uses Akismet to reduce spam. Learn how your comment data is processed.