<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="http://forums.method.me/cs/utility/FeedStylesheets/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/"><channel><title>Method:API Q&amp;A</title><link>http://forums.method.me/cs/forums/15.aspx</link><description>Ask questions specific to the MethodAPI from the Method Team and other Method users.</description><dc:language>en</dc:language><generator>CommunityServer 2007.1 SP2 (Build: 31113.47)</generator><item><title>Re: How to Create an Item from API?</title><link>http://forums.method.me/cs/forums/thread/36704.aspx</link><pubDate>Fri, 20 Jan 2023 22:37:28 GMT</pubDate><guid isPermaLink="false">3393c1ec-311b-4812-96cb-ad8c611bba4f:36704</guid><dc:creator>Method_Paul</dc:creator><slash:comments>0</slash:comments><comments>http://forums.method.me/cs/forums/thread/36704.aspx</comments><wfw:commentRss>http://forums.method.me/cs/forums/commentrss.aspx?SectionID=15&amp;PostID=36704</wfw:commentRss><description>&lt;p&gt;&lt;span id="mce_0_start" style="overflow:hidden;"&gt;Here&amp;#39;s the trick, you need to add to the ItemInventory table, not the Item table. &lt;span id="mce_1_start" style="overflow:hidden;"&gt;Kinda confusing....but the Item table is more of a &amp;quot;view&amp;quot; of all the types of item tables. &amp;nbsp;And yes, we should be making that more obvious via the API.&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;I tried, using PostMan to create an item in the ItemInventory table, and can confirm that Name, Purchase Description and Sales Description all showed up perfectly.&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;div&gt;
&lt;div&gt;&lt;span&gt;&amp;quot;Name&amp;quot;&lt;/span&gt;&lt;span&gt;:&lt;/span&gt; &lt;span&gt;&amp;quot;Test Item3&amp;quot;&lt;/span&gt;&lt;span&gt;,&lt;/span&gt;&lt;/div&gt;
&lt;div&gt;&lt;span&gt;&amp;quot;IsActive&amp;quot;&lt;/span&gt;&lt;span&gt;:&lt;/span&gt; &lt;span&gt;true&lt;/span&gt;&lt;span&gt;,&lt;/span&gt;&lt;/div&gt;
&lt;div&gt;&lt;span&gt;&amp;quot;IncomeAccount&amp;quot;&lt;/span&gt;&lt;span&gt;:&lt;/span&gt; &lt;span&gt;&amp;quot;Integration:Sales&amp;quot;&lt;/span&gt;&lt;span&gt;,&lt;/span&gt;&lt;/div&gt;
&lt;div&gt;&lt;span&gt;&amp;quot;AssetAccount&amp;quot;&lt;/span&gt;&lt;span&gt;:&lt;/span&gt; &lt;span&gt;&amp;quot;Inventory Asset-1&amp;quot;&lt;/span&gt;&lt;span&gt;,&lt;/span&gt;&lt;/div&gt;
&lt;div&gt;&lt;span&gt;&amp;quot;COGSAccount&amp;quot;&lt;/span&gt; &lt;span&gt;:&lt;/span&gt; &lt;span&gt;&amp;quot;Cost of Goods Sold&amp;quot;&lt;/span&gt;&lt;span&gt;,&lt;/span&gt;&lt;/div&gt;
&lt;div&gt;&lt;span&gt;&amp;quot;IsTrackQtyOnHand&amp;quot;&lt;/span&gt; &lt;span&gt;:&lt;/span&gt; &lt;span&gt;true&lt;/span&gt;&lt;span&gt;,&lt;/span&gt;&lt;/div&gt;
&lt;div&gt;&lt;span&gt;&amp;quot;PurchaseCast&amp;quot;&lt;/span&gt; &lt;span&gt;:&lt;/span&gt; &lt;span&gt;0&lt;/span&gt;&lt;span&gt;,&lt;/span&gt;&lt;/div&gt;
&lt;div&gt;&lt;span&gt;&amp;quot;SalesPrice&amp;quot;&lt;/span&gt; &lt;span&gt;:&lt;/span&gt; &lt;span&gt;0&lt;/span&gt;&lt;span&gt;,&lt;/span&gt;&lt;/div&gt;
&lt;div&gt;&lt;span&gt;&amp;quot;PurchaseDesc&amp;quot;&lt;/span&gt; &lt;span&gt;:&lt;/span&gt; &lt;span&gt;&amp;quot;This is a purchase description.&amp;quot;&lt;/span&gt;&lt;span&gt;,&lt;/span&gt;&lt;/div&gt;
&lt;div&gt;&lt;span&gt;&amp;quot;SalesDesc&amp;quot;&lt;/span&gt; &lt;span&gt;:&lt;/span&gt; &lt;span&gt;&amp;quot;This is a sales description.&amp;quot;&lt;/span&gt;&lt;/div&gt;
&lt;/div&gt;</description></item><item><title>Re: How to Create an Item from API?</title><link>http://forums.method.me/cs/forums/thread/36702.aspx</link><pubDate>Thu, 19 Jan 2023 20:41:44 GMT</pubDate><guid isPermaLink="false">3393c1ec-311b-4812-96cb-ad8c611bba4f:36702</guid><dc:creator>jamieroyce</dc:creator><slash:comments>0</slash:comments><comments>http://forums.method.me/cs/forums/thread/36702.aspx</comments><wfw:commentRss>http://forums.method.me/cs/forums/commentrss.aspx?SectionID=15&amp;PostID=36702</wfw:commentRss><description>&lt;p&gt;&lt;span id="mce_0_start" style="overflow:hidden;"&gt;I tried this all the way down to just one field and have not found a way to get the Item Name or Description to add.&amp;nbsp;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;curl --location --request POST &amp;#39;https://rest.method.me/api/v1/tables/item&amp;#39; \&lt;br /&gt;--header &amp;#39;Authorization: APIKey **&amp;#39; \&lt;br /&gt;--header &amp;#39;Content-Type: application/json&amp;#39; \&lt;br /&gt;--data-raw &amp;#39;{&lt;br /&gt; &amp;quot;&lt;span id="mce_2_start" style="overflow:hidden;"&gt;Name&lt;/span&gt;&amp;quot;: &amp;quot;dB Technologies USA Inc&amp;quot;&lt;br /&gt;}&lt;br /&gt;&amp;#39;&lt;/p&gt;
&lt;p&gt;I tried just SalesDesc, etc. and none populate the Item Desc field.&amp;nbsp;&lt;/p&gt;</description></item><item><title>Re: How to Create an Item from API?</title><link>http://forums.method.me/cs/forums/thread/36701.aspx</link><pubDate>Thu, 19 Jan 2023 20:12:47 GMT</pubDate><guid isPermaLink="false">3393c1ec-311b-4812-96cb-ad8c611bba4f:36701</guid><dc:creator>Method_Paul</dc:creator><slash:comments>0</slash:comments><comments>http://forums.method.me/cs/forums/thread/36701.aspx</comments><wfw:commentRss>http://forums.method.me/cs/forums/commentrss.aspx?SectionID=15&amp;PostID=36701</wfw:commentRss><description>&lt;p&gt;&lt;span id="mce_0_start" style="overflow:hidden;"&gt;Jamie - I&amp;#39;ll try a quick answer before the support and/or product teams chime in. On first glance, I &lt;span id="mce_1_start" style="overflow:hidden;"&gt;would try a few things:&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span id="mce_0_start" style="overflow:hidden;"&gt;&lt;span id="mce_1_start" style="overflow:hidden;"&gt;&lt;/span&gt;&lt;/span&gt;a) Don&amp;#39;t include FullName. FullName is really a calculated field. It figures out FullName based on the Name as as well as the reference to a Parent, if there is one. &amp;nbsp;I wonder if including FullName is throwing it off somehow, and somehow causing the Name to be blank.&lt;/p&gt;
&lt;p&gt;b) I would &lt;span id="mce_2_start" style="overflow:hidden;"&gt;&lt;/span&gt;try not including&amp;nbsp;&lt;span id="mce_3_start" style="overflow:hidden;"&gt;&lt;span&gt;PrefVendor_RecordID,&amp;nbsp;&lt;span id="mce_4_start" style="overflow:hidden;"&gt;&lt;span&gt;QuantityOnHand for now to see if that makes a difference. Those are bonus fields...introduce them one at a time to something that is working.&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="overflow:hidden;"&gt;&lt;span&gt;&lt;span style="overflow:hidden;"&gt;&lt;span&gt;c) Description - on Inventory, you want to set both the purchase description as well as the sales description. They might be different. &amp;nbsp;In your example, your description was an empty string, so makes sens&lt;span id="mce_6_start" style="overflow:hidden;"&gt;&lt;/span&gt;e.&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;Hopefully that helps.&amp;nbsp;&lt;/p&gt;</description></item><item><title>How to Create an Item from API?</title><link>http://forums.method.me/cs/forums/thread/36700.aspx</link><pubDate>Thu, 19 Jan 2023 19:47:46 GMT</pubDate><guid isPermaLink="false">3393c1ec-311b-4812-96cb-ad8c611bba4f:36700</guid><dc:creator>jamieroyce</dc:creator><slash:comments>0</slash:comments><comments>http://forums.method.me/cs/forums/thread/36700.aspx</comments><wfw:commentRss>http://forums.method.me/cs/forums/commentrss.aspx?SectionID=15&amp;PostID=36700</wfw:commentRss><description>&lt;p&gt;&lt;span id="mce_0_start" style="overflow:hidden;"&gt;I have been using the Method API for a couple years now and even when things are not clearly documented I have been able to figure them out from the examples in the API docs. However I have not been able to successfully create an Item through the API.&amp;nbsp;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span id="mce_1_start" style="overflow:hidden;"&gt;&lt;/span&gt;For example, I tried posting this item with this API call:&amp;nbsp;&lt;/p&gt;
&lt;p&gt;curl --location --request POST &amp;#39;https://rest.method.me/api/v1/tables/item&amp;#39; \&lt;/p&gt;
&lt;p&gt;--header &amp;#39;Authorization: APIKey ***&amp;#39; \&lt;br /&gt;--header &amp;#39;Content-Type: application/json&amp;#39; \&lt;br /&gt;--data-raw &amp;#39;{&lt;br /&gt; &amp;quot;ItemType&amp;quot;: &amp;quot;Inventory&amp;quot;,&lt;br /&gt; &amp;quot;FullName&amp;quot;: &amp;quot;dB Technologies USA Inc&amp;quot;,&lt;br /&gt; &amp;quot;IsActive&amp;quot;: true,&lt;br /&gt; &amp;quot;Name&amp;quot;: &amp;quot;dB Technologies USA Inc&amp;quot;,&lt;br /&gt; &amp;quot;PurchaseCost&amp;quot;:&amp;quot;0&amp;quot;,&lt;br /&gt; &amp;quot;SalesDesc&amp;quot;: &amp;quot;&amp;quot;,&lt;br /&gt; &amp;quot;QuantityOnHand&amp;quot;: &amp;quot;1&amp;quot;,&lt;br /&gt; &amp;quot;IncomeAccount&amp;quot;: &amp;quot;Integration:Sales&amp;quot;,&lt;br /&gt; &amp;quot;COGSAccount&amp;quot;: &amp;quot;Cost of Goods Sold&amp;quot;,&lt;br /&gt; &amp;quot;AssetAccount&amp;quot;: &amp;quot;Inventory Asset-1&amp;quot;, &lt;br /&gt; &amp;quot;PrefVendor_RecordID&amp;quot;: 4377&lt;br /&gt; }&lt;br /&gt;&amp;#39;&lt;br /&gt;&lt;br /&gt;It sucessfully creates a new record, but there is no Name or Description. The other fields do show up.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;What do I need to change to be able to create a new Item so the name and description shows up?&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Does someone have an example API post?&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;</description></item></channel></rss>