Questions tagged as 'json'

1
answer

Error 404 when using Sky Ecommerce API

I'm trying to make a request via API to make sales via credit card. Manual URL: link JSON informed by SKY { "MerchantOrderId":"2014111703", "Customer":{ "Name":"Comprador crédito simples" }, "Payment":{ "Type":"C...
asked by 19.09.2018 / 20:28
1
answer

Format object with array of objects in properties - variable scope problem

Good morning, I have a problem with returning a webservice, I make a query to get Categories, and then another to get the items in that category. The goal is to set a return on the pattern: { "categoryId" : 1, <--- resultad...
asked by 10.09.2018 / 03:19
1
answer

ERROR accessing JSON keys with special character

Good evening, guys! I'm writing a NodeJS that accesses a URL that contains a JSON in that JSON the keys contain special "-" character that is causing error in my application what would be the correct way to access them? Example Error:...
asked by 04.09.2018 / 04:24
1
answer

Error 415 when posting to json for api

import json import requests #criando categoria r0_categoria_dc = {"chave": "r0_formulario", "titulo": "r0_dados_academico", "descricao": "r0_armazena_dados"} r0_categoria_js = json.dumps(r0_categoria_dc) print(r0_categoria_js) r0_obj = requests.p...
asked by 01.09.2018 / 21:35
2
answers

JSON dynamic and popular DataTable

I am having problems generating a JSON message dynamically and popularly a DataTable. When I do it works as follows: var dataSet = [ [ “1”, “01/10/2018”, “200,00” ], [ “2”, “01/11/2018”, “250,00” ], [ “3”, “01/12/2018”, “350,00” ]...
asked by 30.08.2018 / 21:07
0
answers

How to store an Object in Firebase and use in Ionic 3

I want to store the following data in Firebase and use it in Ionic 3, but I did not find any clear documentation that could help me. Can someone give me a way? Follow the code showing the object inside my home.ts initializeItems(...
asked by 30.08.2018 / 19:50
1
answer

Vector size in a JSON in Shell Script

I'd like to get the size of a vector in a JSON in the scriipt shell but I'm only getting the size of each vector string, ie for the example: #!/bin/bash j='{"Nomes": { "nome": ["maria", "jose", "vitor","caio"] }}' echo $j echo $j | jq -r "....
asked by 07.09.2018 / 22:17
1
answer

chrome.tabs.executeScript does not work in background

I would like, when I clicked the extension button, I wrote in the console the title of the page. My current code is this:    background.js chrome.browserAction.onClicked.addListener(function() { chrome.tabs.executeScript(null...
asked by 02.09.2018 / 10:00
0
answers

Adding DataTable rows

I have a table, which I need to populate it dynamically as the user adds the information. How can I get this information, do I already have the function that picks up, and add in the DataTable? Here is the function I get the filled fields: fu...
asked by 21.08.2018 / 21:50
1
answer

Change JSON Response in php

Hello friends I need to change the answer in json but I can not. follows: $ch = curl_init('http://sams-api.arar.local/send'); curl_setopt($ch, CURLOPT_POST, 1); curl_setopt($ch, CURLOPT_POSTFIELDS, 'phone_number=' . $phoneNum...
asked by 24.08.2018 / 16:56