-
Notifications
You must be signed in to change notification settings - Fork 8
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
deal_associations #24
Comments
Nope! |
Ah! I got zero row before my edits as well. Do you have an expected output that you could copy paste here? |
|
The issue might start in get_deals actually, see below, I get no associations, I'll look at the raw JSON now. library("hubspot")
deals <- get_deals(
max_iter = 10,
max_properties = 1,
associations = "true"
)
deals
#> $`931633510`
#> $`931633510`$portalId
#> [1] 62515
#>
#> $`931633510`$dealId
#> [1] 931633510
#>
#> $`931633510`$isDeleted
#> [1] FALSE
#>
#> $`931633510`$associations
#> $`931633510`$associations$associatedVids
#> list()
#>
#> $`931633510`$associations$associatedCompanyIds
#> list()
#>
#> $`931633510`$associations$associatedDealIds
#> list()
#>
#> $`931633510`$associations$associatedTicketIds
#> list()
#>
#>
#> $`931633510`$properties
#> $`931633510`$properties$amount_in_home_currency
#> $`931633510`$properties$amount_in_home_currency$value
#> [1] "100"
#>
#> $`931633510`$properties$amount_in_home_currency$timestamp
#> [1] 1.565734e+12
#>
#> $`931633510`$properties$amount_in_home_currency$source
#> [1] "CALCULATED"
#>
#> $`931633510`$properties$amount_in_home_currency$sourceId
#> NULL
#>
#> $`931633510`$properties$amount_in_home_currency$versions
#> $`931633510`$properties$amount_in_home_currency$versions[[1]]
#> $`931633510`$properties$amount_in_home_currency$versions[[1]]$name
#> [1] "amount_in_home_currency"
#>
#> $`931633510`$properties$amount_in_home_currency$versions[[1]]$value
#> [1] "100"
#>
#> $`931633510`$properties$amount_in_home_currency$versions[[1]]$timestamp
#> [1] 1.565734e+12
#>
#> $`931633510`$properties$amount_in_home_currency$versions[[1]]$source
#> [1] "CALCULATED"
#>
#> $`931633510`$properties$amount_in_home_currency$versions[[1]]$sourceVid
#> list()
#>
#> $`931633510`$properties$amount_in_home_currency$versions[[1]]$sourceMetadata
#> [1] ""
#>
#>
#>
#>
#>
#> $`931633510`$imports
#> list()
#>
#> $`931633510`$stateChanges
#> list()
purrr::map(deals, "association")
#> $`931633510`
#> NULL Created on 2019-10-21 by the reprex package (v0.3.0) |
Mmmh @stephlocke https://api.hubapi.com/deals/v1/deal/paged?hapikey=demo&includeAssociations=true&limit=2&properties=dealname does not show associations so is there an issue with the API itself? It's the URL from the docs but the JSON I see is different from the one in the docs... |
I wonder if this might be an option https://developers.hubspot.com/docs/methods/crm-associations/crm-associations-overview |
set by whom? |
actually no, it's only got a single object interface not a list interface |
do you agree that it's weird not to get the same object as the docs website? should I raise an issue "there"? (not sure where, prob the forum) |
yeah, that seems sensible |
well my "bug report" was marked as spam 🙃 I wrote a bug report for that too, let's see if my question gets through eventually 😅 |
Given the answer on the forum, it seems I won't be able to get associations for deals with the demo API key. I'll try next week with the LD API key, but what does this mean for external contributors? I hope there won't often be the case where something just can't be tackled with the demo API key. |
We could create our own example account? |
How much work would it be to create the fake data? |
Not a huge amount. We only need a couple of contacts and deals to begin with :) we can expand as required |
@stephlocke is it expected that
deal_associations()
returns 0 row?The text was updated successfully, but these errors were encountered: