-
Notifications
You must be signed in to change notification settings - Fork 10
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
Bulk export API #3
Comments
I've never used "bulk" endpoints before. |
Thanks... I'll wait for your bulk endpoint changes...
…On Sun, Aug 20, 2017 at 1:56 PM, Hidenari Nozaki ***@***.***> wrote:
I've never used "bulk" endpoints before.
I didn't know that Marketo's URLs are different for bulk.
I need to change my code.
Not sure how long it'll take but I'll have a look.
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
<#3 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AX0pQCMevc3Hgi_8BPN6UWKFGSiZhBscks5saJ2MgaJpZM4O8sNi>
.
|
Give it a try. |
It's worked.. Thanks..
next question.
whether it will support POST call with no request body like in below
case.... exportId in the url changes.
POST /bulk/v1/activities/export/{exportId}/enqueue.json
…On Sun, Aug 20, 2017 at 2:33 PM, Hidenari Nozaki ***@***.***> wrote:
Give it a try.
Now you need to specify the path all the time like this:
/rest/v1/leads.json
/bulk/v1/activities/export/create.json
Which is a good thing I suppose. It's more explicit.
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
<#3 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AX0pQCvsOwYHnlUMZ4i5iBi2oHSEE-xMks5saKY3gaJpZM4O8sNi>
.
|
Also need a support to download the data which is in CSV format.
…On Sun, Aug 20, 2017 at 5:55 PM, suraj birla ***@***.***> wrote:
It's worked.. Thanks..
next question.
whether it will support POST call with no request body like in below
case.... exportId in the url changes.
POST /bulk/v1/activities/export/{exportId}/enqueue.json
On Sun, Aug 20, 2017 at 2:33 PM, Hidenari Nozaki ***@***.***
> wrote:
> Give it a try.
> Now you need to specify the path all the time like this:
> /rest/v1/leads.json
> /bulk/v1/activities/export/create.json
> Which is a good thing I suppose. It's more explicit.
>
> —
> You are receiving this because you authored the thread.
> Reply to this email directly, view it on GitHub
> <#3 (comment)>,
> or mute the thread
> <https://github.com/notifications/unsubscribe-auth/AX0pQCvsOwYHnlUMZ4i5iBi2oHSEE-xMks5saKY3gaJpZM4O8sNi>
> .
>
|
Bulk API is quite different from REST-based JSON API. |
Hi,
I'm trying to use get data of marketo using bulk api. here is my code..
package main
import(
"github.com/SpeakData/minimarketo"
"log"
"encoding/json"
"fmt"
)
type DataRangeType struct {
StartAt string
json:"startAt"
EndAt string
json:"endAt"
}
type ActivityType1 struct {
ActivityTypeIds []int
json:"activityTypeIds"
}
type FilterType struct {
CreatedAt DataRangeType
json:"createdAt"
ActivityTypeIds []int
json:"activityTypeIds"
}
type InputActivity1 struct {
Format string
json:"format"
Filter FilterType
json:"filtertype"
}
type BulkOutputResult struct {
RequestID string
json:"requestId"
Success bool
json:"success"
Result []struct {
ExportID string
json:"exportId"
Status string
json:"status"
CreatedAt string
json:"createdAt"
QueuedAt string
json:"queuedAt"
Format string
json:"format"
}
json:"result"
}
func main() {
config := minimarketo.ClientConfig{
ID: "ID",
Secret: "SCRET",
Endpoint: "https://XYZ.mktorest.com",
Debug: true,
}
fmt.Println("before calling client")
client, err := minimarketo.NewClient(config)
if err != nil {
log.Fatal(err)
}
}
Getting an error . Can you please let me know where I'm making a mistake.
2017/08/20 18:25:31 [minimarketo/Post] /bulk/v1/activities/export/create.json, {"format":"CSV","filtertype":{"createdAt":{"startAt":"2017-01-21T11:47:30-08:00","endAt":"2017-01-21T11:47:30-08:00"},"activityTypeIds":[12,1]}}
2017/08/20 18:25:31 [minimarketo/do] URL: https://XYZ.mktorest.com/rest/v1/bulk/v1/activities/export/create.json
2017/08/20 18:25:31 [minimarketo/do] DONE: body
2017/08/20 18:25:31 [minimarketo/Post] DONE
error in post
2017/08/20 18:25:31 No body! Check URL: https://XYZ.mktorest.com/rest/v1/bulk/v1/activities/export/create.json
The text was updated successfully, but these errors were encountered: