-
Notifications
You must be signed in to change notification settings - Fork 41
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
Updating Campaign #23
Comments
Hi! What have you tryed so far? Once you have the campaign as -> $campaign. You should change whatever you want with the setters: $campaign->setName("New campaign name"); And, later call the save method $campaign->save(); Have you tried this? Thanks |
I have tried this, main problem is that, I don't know how to pass the campaign id. I don't know the first step having campaign as -> $campaign. |
Oh! Okey! You have two possibilities, if you create a new campaign with the sdk is easy, because when you create it you have the variable. If you want to retrieve the campaign using the id you should use: $campaign = new Campaign($account); This should work :) |
Thank you so much for your instant help 😄 PHP Fatal error: Uncaught exception 'Hborras\TwitterAdsSDK\TwitterAds\Errors\NotFound' with message 'NOT_FOUND' in /var/www/html/twitter-php-ads-sdk-master/src/TwitterAds.php:432 |
It looks like the resource you're tryning to get doesn't exist. Looking into the Stack Trace, I see that here: /var/www/html/twitter-php-ads-sdk-master/examples/quick_start.php(25): Hborras\TwitterAdsSDK\TwitterAds\Resource->load('10119006') You'retring to load id '10119006', but you can't use numbers in base 10 in the API, you should transform it before to base 36. Is the way Twitter works. http://www.unitconversion.org/numbers/base-10-to-base-36-conversion.html |
Thank you 👍 |
I want to update campaign using this sdk, but I am not able to do so. If you are having an example for that , it would be great. I am able to create campaign but not update.
The text was updated successfully, but these errors were encountered: