Closed rusyag closed 2 years ago
What is the exact URL you use (with parameters) for the REST call?
You must use a phone number in international format when using REST api. Since the Region set in the settings is user dependent, and since indeed you cannot be logged in when using REST, the phone number must be in international format (leading + with country code, like +111111111). Maybe that's the problem.
https://github.com/kalkun-sms/Kalkun/blob/b18e4feb508be626bdafa50c196ce0deef5b0633/application/helpers/kalkun_helper.php#L357 https://github.com/kalkun-sms/Kalkun/blob/b18e4feb508be626bdafa50c196ce0deef5b0633/application/helpers/kalkun_helper.php#L358
Yes, I know, and I use the number in the international format.
By the way, if I log in to kalkun before using REST_API, then in the xml response I see a number not in international format.
I updated the wiki https://github.com/kalkun-sms/Kalkun/wiki/Plugin:-REST-Api Please follow it again and tell me if that fixes your issues.
Thank you for the tip. The issue was fixed.
Hello! Sending SMS via REST_API works fine if you log in directly to kalkun before that. But, if this is not done, the request leads to an error.
0.8.0-beta-4-dev [Lang: russian] [CountryCode: RU]
Linux 3299b6bfe081 5.15.0-43-generic #46-Ubuntu SMP Tue Jul 12 10:30:17 UTC 2022 x86_64
8.0.22
MySQLi 10.6.5-MariaDB-1:10.6.5+maria~focal (mysqli)
Gammu 1.42.0, Linux, kernel 5.15.0-43-generic (#46-Ubuntu SMP Tue Jul 12 10:30:17 UTC 2022), GCC 11.2
17
Chrome 104.0.0.0
rest_api