ECGrid Forums  

Go Back   ECGrid Forums > Electronic Commerce > ECGridOS > ECGridOS Developer

ECGridOS Developer Development related posts.

Reply
 
Thread Tools Display Modes
  #1  
Old 08-20-2012, 03:00 PM
Alex Obraztsov Alex Obraztsov is offline
New Member
 
Join Date: Aug 2012
Location: Techdinamics Inc.
Posts: 6
Default Mailbox API issues

Hi guys,

First of all - thank you on great stuff with the API.

Next, I would like to address the following problems I've run into while testing the mailbox API.
1) MailboxX12Delimiters() function (X12 delimiters update) call raises this SQL exception:
Quote:
System.Web.Services.Protocols.SoapException: Server was unable to process request. ---> System.Data.SqlClient.SqlException: Procedure or function 'ECGridOS_MailboxUpdateX12Delimiters' expects parameter '@X12SegTerm', which was not supplied.
2) The second odd thing is that when I call MailboxSuspend() it gets the "Terminated" state instead of "Suspended".
Reply With Quote
  #2  
Old 08-20-2012, 03:28 PM
Todd Gould's Avatar
Todd Gould Todd Gould is offline
Loren Data Corp.
 
Join Date: May 2005
Location: Loren Data Corp.
Posts: 303
Send a message via Skype™ to Todd Gould
Arrow Fixes

Alex,

Thank you for posting this in the forum:

1) I've made the change in the API to correct the MailboxSuspend() causing a Terminate instead of a Suspend. It will be updated later today. Good catch!

2) You uncovered a second bug. I was able to corrrect the Mailbox Delimiters issue in the SQL code itself, so no update to the API code was required. Do note that this only affects data coming INTO this mailbox, not data being sent from this mailbox.

-=tg=-
Reply With Quote
  #3  
Old 08-21-2012, 06:34 PM
Alex Obraztsov Alex Obraztsov is offline
New Member
 
Join Date: Aug 2012
Location: Techdinamics Inc.
Posts: 6
Default

Todd,

Thank you for the quick answer.

Although it's not mailbox API, I got two questions on Trading Partners API:

1) When I try to use TPAddVAN() with NetworkAdmin account and corresponding NetworkID (home network), I get "access denied" exception. Is this function available to this AuthLevel or is it for NetOps only?

2) I was able to get a list of created TP only through TPListEx(), specifying
both Network and Mailbox IDs, since TPList() returns an empty set. What should I do to make the TP available to TPList() function?
Reply With Quote
  #4  
Old 08-21-2012, 09:01 PM
Todd Gould's Avatar
Todd Gould Todd Gould is offline
Loren Data Corp.
 
Join Date: May 2005
Location: Loren Data Corp.
Posts: 303
Send a message via Skype™ to Todd Gould
Lightbulb TPAdd, TPList, TPFind and TPSearch

Alex,

There are three TPAdd fuctions which I will explain:

TPAdd() adds an entry to the current NetworkID/MailboxID of the user that is currently logged in. You can run the WhoAmI() IP to see what that is.

TPAddVAN() allows you to add entries to the specified NetworkID which must be of the Type VAN. This allows you to add your trading partners to networks that are not managing their own data on the system. You cannot add a trading partner to another ECGridOS user-managed account (as you would not probably want someon adding IDs to your account.

TPAddEx() allows you to specify adding entries to any NetworkID/MailboxID to which you have Authority. If you are logged in as a NetworkAdmin or NetworkUser, you can add to any MailboxID on your network. If you are a MailboxAdmin or MailboxUser, you are limited to your own MailboxID, the same functionality as TPAdd().

The TPList functions act similarly:

TPList() only list trading partners in the current NetworkID/MailboxID of the logged in user. TPListEx() allows you to find trading partners on other Mailboxes on your Network if you have Network-level authority. We do not allow you to TPListEx() other networks as you probably would not want others pulling down your entire customer list.

To find ECGridIDs on other networks to set up Interconnects and other functions there is the TPFind and TPSearch set of functions. As before, without the Ex, is only on the current NetworkID/MailboxID. Using NetworkID := -1 and/or MailboxID := -1 allows you to match ANY NetworkID/MailboxID using these functions, allowing you to find trading partners even if you don't know what Network they are on.

Whenever you receive Trading Partner data from other networks, certain personal information is redacted from the response before being passed to you.

Hope this helps. Let me know.
Reply With Quote
  #5  
Old 08-22-2012, 04:12 AM
Alex Obraztsov Alex Obraztsov is offline
New Member
 
Join Date: Aug 2012
Location: Techdinamics Inc.
Posts: 6
Default

Hi Todd,

Thank you for detailed answer!

In other words, I need to use one of specific network IDs for TPAddVAN: 201 Advanced Communications Systems, 250 BCE Emergis (Bell Canada) etc - listed in documentation, am I correct? Is there a way to request this list from the API (e.g. to include recently added, if any)?

As for TPList/TPListEx, suppose I have a NetworkAdmin auth level and my account is bound to specific MailboxID (returned by WhoAmI() call). Then I create a new mailbox and add a TP there, but TPList returns nothing, since the new mailbox ID is different from mine, no matter that I am its owner. Therefore, I have to use TPListEx for administrative purposes.

What concerns "-1" values for MailboxID - thanks, it did the trick! But note, that documentation for TPListEx() states:
Quote:
A value of zero (0) lists all Mailboxes for the specified NetworkID, contingent on Authorization Level.
BTW, I saw similar instruction to use zero in docs for InterconnectListByECGridID() and probably somewhere else.

PS
"Be careful about reading health books. You may die of a misprint." Mark Twain
Reply With Quote
  #6  
Old 08-22-2012, 06:13 PM
Alex Obraztsov Alex Obraztsov is offline
New Member
 
Join Date: Aug 2012
Location: Techdinamics Inc.
Posts: 6
Question

In addition, I got several "access denied" messages today, so I wanted to ask if it is possible:
1) make TPMoveEx() within my own network (where I'm NetworkAdmin) between different mailboxes?
2) edit interconnect status from Completed to Pending - I'm getting the same - access denied. Btw,

Are there any authentication level restrictions, other than described in docs?
Reply With Quote
  #7  
Old 08-22-2012, 06:27 PM
Alex Obraztsov Alex Obraztsov is offline
New Member
 
Join Date: Aug 2012
Location: Techdinamics Inc.
Posts: 6
Default

Quote:
Originally Posted by Alex Obraztsov View Post
1) make TPMoveEx() within my own network (where I'm NetworkAdmin) between different mailboxes?
UPDBtw, http://forums.ecgrid.com/showthread.php?t=190 - found the answer here.
Reply With Quote
  #8  
Old 08-22-2012, 06:32 PM
Todd Gould's Avatar
Todd Gould Todd Gould is offline
Loren Data Corp.
 
Join Date: May 2005
Location: Loren Data Corp.
Posts: 303
Send a message via Skype™ to Todd Gould
Default

Quote:
Originally Posted by Alex Obraztsov View Post
2) edit interconnect status from Completed to Pending - I'm getting the same - access denied.
At the current time, other than InterconnectCancel(), changes to Interconnect Status requires NetOps authorization. I will consider change to that in future versions if you have a good use case. That is noted in the documentation that NetOps is required.

Quote:
Originally Posted by Alex Obraztsov View Post
Btw, Are there any authentication level restrictions, other than described in docs?
I think it is fairly well documented. If you find any errors (and I'm sure there are a few), do let me know.

-=tg=-
Reply With Quote
  #9  
Old 08-22-2012, 06:33 PM
Todd Gould's Avatar
Todd Gould Todd Gould is offline
Loren Data Corp.
 
Join Date: May 2005
Location: Loren Data Corp.
Posts: 303
Send a message via Skype™ to Todd Gould
Default

Quote:
Originally Posted by Alex Obraztsov View Post
UPDBtw, http://forums.ecgrid.com/showthread.php?t=190 - found the answer here.
I'm waiting for a low traffic time to put this update in place.

-=tg=-
Reply With Quote
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Administrative Workflow Todd Gould ECGridOS Developer 7 03-19-2014 06:29 PM
Move TPID from one Mailbox to another Mailbox edewsnap ECGridOS Developer 1 07-05-2012 11:49 AM
Mailbox config timeout elDub ECGridOS Developer 4 08-11-2011 11:12 AM
Managing Mailboxes ProjectDavid ECGridOS Developer 1 09-13-2010 03:39 PM


All times are GMT -4. The time now is 05:02 PM.


Powered by vBulletin® Version 3.8.4
Copyright ©2000 - 2019, vBulletin Solutions, Inc.
ECGrid® is a registered service mark of Loren Data Corp.