This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
curl "http://viasocket.com/t/YFRHZEw2JxDXEsdF"\ | |
-X POST\ | |
-H "authkey: YOUR_AUTH_KEY"\ | |
-H "Content-Type: application/json"\ | |
-d '{"param_name":"param_value","param_name2":"param_value 2"}' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import org.json.simple.JSONObject; | |
import java.io.*; | |
import java.net.URL; | |
import java.net.URLConnection; | |
import java.net.URLEncoder; | |
public class Socket { | |
public static void invoke() { | |
//Your authentication key |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require "net/http" | |
require "uri" | |
require 'json' | |
base_uri = "http://flow.viasocket.com/trigger/team/flow_identifier" #Set your Socket Api | |
base_uri = base_uri + "?param1=value1¶m2=value2" #Set query params | |
uri = URI.parse(base_uri) | |
data = { | |
status: "testing", |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from urllib import urlencode | |
from urllib2 import Request, urlopen | |
authkey = 'YOUR_AUTHKEY' # Set your Auth-Key here | |
url = 'http://flow.viasocket.com/trigger/sample_url/slack_integration' # Set your socket URL here | |
post_fields = {'foo': 'bar'} # Set POST fields here | |
request = Request(url, urlencode(post_fields).encode()) | |
request.add_header('Auth-Key', authkey) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
// The data to send to the Flow | |
$data_string = array( | |
'contact_no' => '999999999', | |
'caller_phone' => '888888888', | |
'company' => 'socket', | |
'branch_info' => 'India', | |
); | |
$postData = json_encode($data_string); | |
$URL = 'FLOW_URL_WITH_AUTH_KEY'; //https://viasocket.com/t/y8K5iJYnC69VM5wMPKJ/my-testing?authkey=zqkUoQdhskfdsfdsf |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//Load the request module | |
var request = require('request'); | |
//Lets configure and request | |
request({ | |
url: 'http://flow.viasocket.com/trigger/sample_url/slack_integration', //Replace with your socket api | |
qs: {from: 'socket sample', time: +new Date()}, //Query string data | |
method: 'POST', | |
headers: { | |
'Content-Type': 'application/json', |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html> | |
<head> | |
<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.12.0/jquery.min.js"></script> | |
<script> | |
$(document).ready(function(){ | |
$("button").click(function(){ | |
$.post("http://flow.viasocket.com/trigger/sample_url/slack_integration"+"?Auth-Key="+"YOUR_AUTHKEY", | |
{ | |
name: "Donald Duck", |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html> | |
<head> | |
<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.12.0/jquery.min.js"></script> | |
<script> | |
$(document).ready(function(){ | |
$("button").click(function(){ | |
$.post("http://flow.viasocket.com/trigger/sample_url/slack_integration"+"?Auth-Key="+"YOUR_AUTHKEY", | |
{ | |
name: "Donald Duck", |