# Or a using shortcut during object instantiation
ad_account = FacebookAds::AdAccount.get('act_<YOUR_AD_ACCOUNT_ID>', 'name', {
access_token: <ACCESS_TOKEN>, app_secret: <APP SECRET>
})
When using this syntax you will receive this error:
wrong number of arguments (given 1, expected 0) (ArgumentError)
When using the non shorthand syntax - no issues:
session = FacebookAds::Session.new(access_token: <ACCESS_TOKEN>, app_secret: <APP SECRET>)
ad_account = FacebookAds::AdAccount.get('act_<YOUR_AD_ACCOUNT_ID>', 'name', session)
When using this syntax you will receive this error:
wrong number of arguments (given 1, expected 0) (ArgumentError)When using the non shorthand syntax - no issues: