Skip to content

Commit

Permalink
Merge pull request #7 from ywchang0612/master
Browse files Browse the repository at this point in the history
Fix endpoint according to Mitake official document
  • Loading branch information
minchao authored Dec 7, 2021
2 parents 2885fcc + c875ff6 commit 77895d1
Showing 1 changed file with 8 additions and 8 deletions.
16 changes: 8 additions & 8 deletions src/API.php
Original file line number Diff line number Diff line change
Expand Up @@ -105,10 +105,10 @@ public function sendLongMessageBatch(array $messages)
$request = $this->client->newRequest(
'POST',
$this->client->buildUriWithQuery(
$this->client->getLongMessageBaseURL() . '/SpLmPost',
$this->client->getLongMessageBaseURL() . '/api/mtk/SmBulkSend',
['Encoding_PostIn' => 'UTF8']
),
'text/plain',
'application/x-www-form-urlencoded',
$body
);

Expand Down Expand Up @@ -139,8 +139,8 @@ public function sendLongMessage(Message\LongMessage $message)
public function queryAccountPoint()
{
$request = $this->client->newRequest(
'GET',
$this->client->buildUriWithQuery('/SmQueryGet.asp')
'POST',
$this->client->buildUriWithQuery('/api/mtk/SmQuery')
);

$response = $this->client->sendRequest($request);
Expand All @@ -162,8 +162,8 @@ public function queryAccountPoint()
public function queryMessageStatus(array $ids)
{
$request = $this->client->newRequest(
'GET',
$this->client->buildUriWithQuery('/SmQueryGet.asp', ['msgid' => implode(',', $ids)])
'POST',
$this->client->buildUriWithQuery('/api/mtk/SmQuery', ['msgid' => implode(',', $ids)])
);

$response = $this->client->sendRequest($request);
Expand All @@ -181,8 +181,8 @@ public function queryMessageStatus(array $ids)
public function cancelMessageStatus(array $ids)
{
$request = $this->client->newRequest(
'GET',
$this->client->buildUriWithQuery('/SmCancel.asp', ['msgid' => implode(",", $ids)])
'POST',
$this->client->buildUriWithQuery('/api/mtk/SmCancel', ['msgid' => implode(",", $ids)])
);

$response = $this->client->sendRequest($request);
Expand Down

0 comments on commit 77895d1

Please sign in to comment.