Skip to content

Instantly share code, notes, and snippets.

@lfreneda
Created November 29, 2017 10:53
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save lfreneda/fb0160ef1fda29fe27676df5360b5206 to your computer and use it in GitHub Desktop.
Save lfreneda/fb0160ef1fda29fe27676df5360b5206 to your computer and use it in GitHub Desktop.
integrations-curls-calls.sh
```
curl 'http://api.fieldcontrol.com.br/orders/' -H 'Content-Type: application/json;charset=UTF-8' -H 'x-access-token: seu-token-aqui' --data-binary $'{
"address": {
"zipCode": "05005900",
"city": "Sao Paulo",
"state": "SP",
"street": "Rua Turiassu",
"number": "902",
"complement": null,
"neighborhood": null,
"coords": {
"latitude": -23.527028,
"longitude": -46.680823
}
},
"service": {
"id": id-do-servico-aqui
},
"customer": {
"id": id-do-cliente-aqui
},
"description": "Pork chop salami sausage bresaola turkey. Picanha tri-tip turkey, pork loin rump salami strip steak hamburger kevin cow shank leberkas. Andouille pastrami pig tongue, short ribs spare ribs rump.",
"identifier": "OS-15056"
}' --compressed
```
```
curl 'http://api.fieldcontrol.com.br/tasks/' -H 'Content-Type: application/json;charset=UTF-8' -H 'x-access-token: seu-token-aqui' --data-binary $'{
"status":"scheduled",
"employee":{
"id": id-do-colaborador-aqui
},
"scheduling":{
"date":"2017-11-29",
"time":null,
"type":"scheduled-date"
},
"coords":{
"latitude":-23.577140,
"longitude":-46.687977
},
"position":100,
"duration":50,
"order":{
"id":"id-da-ordem-aqui"
}
}' --compressed
```
```
curl 'http://api.fieldcontrol.com.br/employees/' -H 'Content-Type: application/json;charset=UTF-8' -H 'x-access-token: seu-token-aqui'
```
```
curl 'http://api.fieldcontrol.com.br/services/' -H 'Content-Type: application/json;charset=UTF-8' -H 'x-access-token: seu-token-aqui'
```
```
curl 'http://api.fieldcontrol.com.br/customers/' -H 'Content-Type: application/json;charset=UTF-8' -H 'x-access-token: seu-token-aqui'
```
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment