Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Can you provide an example about upload #16

Open
caocaodage opened this issue Jul 14, 2021 · 2 comments
Open

Can you provide an example about upload #16

caocaodage opened this issue Jul 14, 2021 · 2 comments

Comments

@caocaodage
Copy link

I did not find the usage of method /v1/pbx/ivr/sounds/upload

@caocaodage
Copy link
Author

caocaodage commented Jul 14, 2021

`
public function uploadFile($name, $file){
$params = [
"name" => $name,
];
if(!file_exists($file)){
return "falil";
}
$params["file"] = curl_file_create($file);
$data = $this->request("pbx/ivr/sounds/upload", $params, "post");
return $data ;
}

`

i added this to Api.php
it doesnt work

@zadarma-github
Copy link
Collaborator

Your example is correct. Please check the API response.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants