2

We are retrieving the available Data Extensions in an account using the SOAP request:

<?xml version="1.0" encoding="utf-8"?>
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
    <soapenv:Header>
        <wsse:Security soapenv:mustUnderstand="1" xmlns:wsse="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd">
            <wsse:UsernameToken wsu:Id="UsernameToken-32259181" xmlns:wsu="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd">
                <wsse:Username>username</wsse:Username>
                <wsse:Password Type="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-username-token-profile-1.0#PasswordText">password</wsse:Password>
            </wsse:UsernameToken>
        </wsse:Security>
    </soapenv:Header>
    <soapenv:Body>
        <RetrieveRequestMsg xmlns="http://exacttarget.com/wsdl/partnerAPI">
            <RetrieveRequest>
                <ObjectType>DataExtension</ObjectType>
                <Properties>CustomerKey</Properties>
                <Properties>Name</Properties>
            </RetrieveRequest>
        </RetrieveRequestMsg>
    </soapenv:Body>
</soapenv:Envelope>

This works fine. However, I would like to retrieve the folder and subfolder to each Data Extension as it appears in ExactTarget:

data extension folders

That is, for each Data Extension I want to build a breadcrumb trail to the Data Extension like:

Star > 202546_Star-MemberSurvey > NameOfDataExtension

I've checked the Data Extension Objects and note that there is a CategoryID property which looks like it could be related to the folder that the DE resides in, but I'm not sure how to get the name of the folder or retrieve a parent folder.

2 Answers 2

4

you can request "ParentFolder.ID and "ParentFolder.Name" as properties in your DataFolder RetrieveRequest. With that information, you can use recursive logic to match up ParentFolder.ID to ID and rebuild your DataFolder paths.

1

Please see below link for details on how to retrieve folders from your account via the API. I've also included possible ContentType values that are needed. For your use case, you would use "dataextension". Hope this helps!

https://help.exacttarget.com/en/technical_library/web_service_guide/technical_articles/creating_retrieving_updating_and_deleting_folders/

The ContentType is required.  Few possible values:

    content 
    dataextension 
    email
    group 
    image
    job
    list
    publication 
    suppression_list 
    survey
    template 
    triggered_send
    userinitiatedsends
2
  • This is exactly what I needed, thanks for the pointer, its working fine now! Sep 22, 2014 at 5:23
  • Use ContentType asset for content builder folder location Apr 5, 2017 at 2:45

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .