This topic contains 4 replies, has 4 voices, and was last updated by  Duo_Liang 3 months, 1 week ago.

  • Author
    Posts
  • Participant
    KKrumbine
    Newbie
    Member since: 18.01.2018
    Number of posts: 3

    Should I be able to view current packages for all senders under the same account using the API key and .NET SDK?

    I have created a Sandbox account with an additional sender and can successfully create a new package in DRAFT passing only the secondary account as the sender. If i then execute eslClient.PackageService.GetPackages(DocumentPackageStatus.DRAFT, new PageRequest(0)) my resulting collection count is 0.

    Doesn’t the API key have full access to the child senders under the account? Any assistance would be appreciated!

    • This topic was modified 1 year, 1 month ago by  KKrumbine.
    Keymaster
    Haris
    Jedi Master
    Member since: 05.11.2015
    Number of posts: 1450

    Score

    0

    Hi there,

    You can use the completion report to view all the packages created by your senders: https://developer.esignlive.com/guides/feature-guides/completion-report/. If you simply use:

    eslClient.PackageService.GetPackages(DocumentPackageStatus.DRAFT, new PageRequest(0));

    Then, you will be returned only the packages created under the main account owner.


    Haris Haidary
    OneSpan Technical Consultant
    Participant
    KKrumbine
    Newbie
    Member since: 18.01.2018
    Number of posts: 3

    Score

    0

    Sorry for the delayed response. Thanks Harris for the very quick response, your answer was exactly what I was looking for!

    -Keith

    Participant
    amcdowell
    Newbie
    Member since: 15.08.2018
    Number of posts: 3

    Score

    0

    Is there a way to retrieve all packages for a given sender instead of all packages for the account?

    Keymaster
    Duo_Liang
    Guru
    Member since: 14.06.2018
    Number of posts: 691

    Score

    0

    Hi amcdowell,

    There’re few ways to do so:
    #1. if you want to use the Completion Report feature, there’s an overwrite function in ReportService:

    public string DownloadCompletionReportAsCSV(Silanis.ESL.SDK.DocumentPackageStatus packageStatus, String senderId, DateTime from, DateTime to)

    Which allows you to input a sender ID as the parameter.

    #2. if you want to retrieve the complete Package Metadata instead of the Completion Report, you can:
    – First, retrieve your sender’s API KEY by this API call (using your owner’s API KEY):

    GET /api/account/senders/{senderId}/apiKey

    Currently, this function is not available in the SDK, but I can create some sample code using REST method in .NET if you want.
    – Then use this API KEY to create a new EslClient object and call the function

     public Page GetPackages(DocumentPackageStatus status, PageRequest request)

    Hope this could help!
    Duo


    Duo Liang
    OneSpan Junior Technical Evangelist

You must be logged in to reply to this topic.