Excusez moi de déterrer un ancien sujet mais j’ai un problème avec l’intégration Tuya :
J’ai changé de fournisseur internet récemment et depuis les lampes que j’utilisais avec l’intégration Tuya ne réponde plus.
Au début, J’ai essayé de supprimer les lampe présentent dans la partie « appareils » de l’intégration pour essayé de le redécouvrir et rien n’était trouvé… J’ai vu ce poste : donc j’ai vérifié mon accès a « IoT Core » (je n’ai pas trouvé « Cloud Develop Base Resouce ») et effectivement la période de Trial était dépassé (aussi j’étais bien sur le cloud Europe Central). J’ai fait une demande de prolongation qui a été acceptée. Depuis j’ai ressayé la découverte et toujours rien…
Mais dans les logs de Gladys j’ai cela quand je valide la configuration :
<warn> service.start.js:44 (Service.start) Unable to st art service tuya Error: connect ETIMEDOUT 2a05:d014:afa:af00:568a:5cc6:4603:c040 :443
at TCPConnectWrap.afterConnect [as oncomplete] (node:net:1555:16) {
errno: -110,
code: 'ETIMEDOUT',
syscall: 'connect',
address: '2xxxx:dxxx:axxxx:af00:568a:5cc6:4603:c040',
port: 443,
config: {
url: 'https://openapi.tuyaeu.com/v1.3/iot-03/devices?last_row_key=&source_id =euxxxxxxxxxxxx&source_type=tuyaUser',
method: 'get',
data: '{}',
headers: {
Accept: 'application/json, text/plain, */*',
t: '1737148959580',
sign: 'xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx',
client_id: 'xxxxxxxxxxxxxxxxxxxxxxxxxxx',
sign_method: 'HMAC-SHA256',
access_token: 'xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx',
Dev_lang: 'Nodejs',
Dev_channel: 'SaaSFramework',
'Signature-Headers': '',
'Content-Type': 'application/json',
'User-Agent': 'axios/0.21.4',
'Content-Length': 2
},
params: {},
transformRequest: [ [Function: transformRequest] ],
transformResponse: [ [Function: transformResponse] ],
timeout: 0,
adapter: [Function: httpAdapter],
xsrfCookieName: 'XSRF-TOKEN',
xsrfHeaderName: 'X-XSRF-TOKEN',
maxContentLength: -1,
maxBodyLength: -1,
validateStatus: [Function: validateStatus],
transitional: {
silentJSONParsing: true,
forcedJSONParsing: true,
clarifyTimeoutError: false
}
},
request: <ref *1> Writable {
_writableState: WritableState {
objectMode: false,
highWaterMark: 16384,
finalCalled: false,
needDrain: false,
ending: false,
ended: false,
finished: false,
destroyed: false,
decodeStrings: true,
defaultEncoding: 'utf8',
length: 0,
writing: false,
corked: 0,
sync: true,
bufferProcessing: false,
onwrite: [Function: bound onwrite],
writecb: null,
writelen: 0,
afterWriteTickInfo: null,
buffered: [],
bufferedIndex: 0,
allBuffers: true,
allNoop: true,
pendingcb: 0,
constructed: true,
prefinished: false,
errorEmitted: false,
emitClose: true,
autoDestroy: true,
errored: null,
closed: false,
closeEmitted: false,
[Symbol(kOnFinished)]: []
},
_events: [Object: null prototype] {
response: [Function: handleResponse],
error: [Function: handleRequestError]
},
_eventsCount: 2,
_maxListeners: undefined,
_options: {
maxRedirects: 21,
maxBodyLength: 10485760,
protocol: 'https:',
path: '/v1.3/iot-03/devices?last_row_key=&source_id=euxxxxxxxxxxxxxxxxxxx&s ource_type=tuyaUser',
method: 'GET',
headers: [Object],
agent: undefined,
agents: [Object],
auth: undefined,
hostname: 'openapi.tuyaeu.com',
port: null,
nativeProtocols: [Object],
pathname: '/v1.3/iot-03/devices',
search: '?last_row_key=&source_id=euxxxxxxxxxxxxxxxxxxxxxxx&source_type=tuyaUser'
},
_ended: false,
_ending: true,
_redirectCount: 0,
_redirects: [],
_requestBodyLength: 2,
_requestBodyBuffers: [ [Object] ],
_onNativeResponse: [Function (anonymous)],
_currentRequest: ClientRequest {
_events: [Object: null prototype],
_eventsCount: 7,
_maxListeners: undefined,
outputData: [],
outputSize: 0,
writable: true,
destroyed: false,
_last: true,
chunkedEncoding: false,
shouldKeepAlive: false,
maxRequestsOnConnectionReached: false,
_defaultKeepAlive: true,
useChunkedEncodingByDefault: false,
sendDate: false,
_removedConnection: false,
_removedContLen: false,
_removedTE: false,
strictContentLength: false,
_contentLength: 2,
_hasBody: true,
_trailer: '',
finished: false,
_headerSent: true,
_closed: false,
socket: [TLSSocket],
_header: 'GET /v1.3/iot-03/devices?last_row_key=&source_id=euxxxxxxxxxxxxxxx AowJC&source_type=tuyaUser HTTP/1.1\r\n' +
'Accept: application/json, text/plain, */*\r\n' +
't: 1737148959580\r\n' +
'sign: xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx\ r\n' +
'client_id: xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx\r\n' +
'sign_method: HMAC-SHA256\r\n' +
'access_token: xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx\r\n' +
'Dev_lang: Nodejs\r\n' +
'Dev_channel: SaaSFramework\r\n' +
'Signature-Headers: \r\n' +
'Content-Type: application/json\r\n' +
'User-Agent: axios/0.21.4\r\n' +
'Content-Length: 2\r\n' +
'Host: openapi.tuyaeu.com\r\n' +
'Connection: close\r\n' +
'\r\n',
_keepAliveTimeout: 0,
_onPendingData: [Function: nop],
agent: [Agent],
socketPath: undefined,
method: 'GET',
maxHeaderSize: undefined,
insecureHTTPParser: undefined,
joinDuplicateHeaders: undefined,
path: '/v1.3/iot-03/devices?last_row_key=&source_id=euxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx&s ource_type=tuyaUser',
_ended: false,
res: null,
aborted: false,
timeoutCb: null,
upgradeOrConnect: false,
parser: null,
maxHeadersCount: null,
reusedSocket: false,
host: 'openapi.tuyaeu.com',
protocol: 'https:',
_redirectable: [Circular *1],
[Symbol(kCapture)]: false,
[Symbol(kBytesWritten)]: 0,
[Symbol(kNeedDrain)]: false,
[Symbol(corked)]: 0,
[Symbol(kOutHeaders)]: [Object: null prototype],
[Symbol(errored)]: null,
[Symbol(kHighWaterMark)]: 16384,
[Symbol(kRejectNonStandardBodyWrites)]: false,
[Symbol(kUniqueHeaders)]: null
},
_currentUrl: 'https://openapi.tuyaeu.com/v1.3/iot-03/devices?last_row_key=&s ource_id=euxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx&source_type=tuyaUser',
[Symbol(kCapture)]: false
},
response: undefined,
isAxiosError: true,
toJSON: [Function: toJSON]
}
Il semblerais que cela Timeout mais je ne sais pas pourquoi…
Cela fonctionne sans problème avec l’application Smart Home de mon Tél et j’arrive a pinger sans problème une lampe depuis Gladys.
Je me demande si l’url de l’api on changé ou que sais-je ?! ^^