<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: api v1 REST checkin in Fusion Manage Forum</title>
    <link>https://forums.autodesk.com/t5/fusion-manage-forum/api-v1-rest-checkin/m-p/5772195#M6143</link>
    <description>&lt;P&gt;Greetings.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Please refer to this article as there a fix that you may be looking for. &amp;nbsp;Seems tho threads interested in same topic, so I'm unifying&amp;nbsp;the audience and interested parties. &amp;nbsp;Kudos to @Anonymous﻿&amp;nbsp;and his development team for discovering the fileVersion missing default behavior~!&lt;/P&gt;
&lt;P&gt;Hope this helps,&lt;/P&gt;</description>
    <pubDate>Fri, 14 Aug 2015 19:59:27 GMT</pubDate>
    <dc:creator>gasevsm</dc:creator>
    <dc:date>2015-08-14T19:59:27Z</dc:date>
    <item>
      <title>api v1 REST checkin</title>
      <link>https://forums.autodesk.com/t5/fusion-manage-forum/api-v1-rest-checkin/m-p/5695197#M6131</link>
      <description>&lt;P&gt;Hi. I'm working on PLM360 addin and I have some problems with it. I've found some difference between api v2 and the current. In api v2 FileUploadRequest object was send in request body. Api v1 checkin specs doesn't contain any info about body in request. Please give me any C# example how to organize my api v1 checkIn request.&lt;/P&gt;&lt;P&gt;Best regards, Dmitrij.&lt;/P&gt;</description>
      <pubDate>Fri, 26 Jun 2015 15:10:54 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/fusion-manage-forum/api-v1-rest-checkin/m-p/5695197#M6131</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2015-06-26T15:10:54Z</dc:date>
    </item>
    <item>
      <title>Re: api v1 REST checkin</title>
      <link>https://forums.autodesk.com/t5/fusion-manage-forum/api-v1-rest-checkin/m-p/5697983#M6132</link>
      <description>&lt;P&gt;Hi Dmitrij,&lt;/P&gt;
&lt;P&gt;Please review the following help page for schema and example on how to do checkin via API v1.&amp;nbsp;&lt;A href="http://help.autodesk.com/view/PLM/ENU/?guid=GUID-2A356A1D-F64E-436A-9A2B-7C83D1E70E2B" target="_blank"&gt;http://help.autodesk.com/view/PLM/ENU/?guid=GUID-2A356A1D-F64E-436A-9A2B-7C83D1E70E2B&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN style="line-height: 15px;"&gt;Hope this helps,&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 29 Jun 2015 16:39:57 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/fusion-manage-forum/api-v1-rest-checkin/m-p/5697983#M6132</guid>
      <dc:creator>gasevsm</dc:creator>
      <dc:date>2015-06-29T16:39:57Z</dc:date>
    </item>
    <item>
      <title>Re: api v1 REST checkin</title>
      <link>https://forums.autodesk.com/t5/fusion-manage-forum/api-v1-rest-checkin/m-p/5699772#M6133</link>
      <description>&lt;P&gt;Thank you for reply,&amp;nbsp;&lt;SPAN&gt;Martin! Follow to &lt;A href="http://help.autodesk.com/view/PLM/ENU/?guid=GUID-CB766836-98D8-4E46-BB7B-C031B4B6DCD4" target="_self"&gt;sepecs&lt;/A&gt;&amp;nbsp;I've always have 415 error: "&lt;/SPAN&gt;&lt;SPAN&gt;The server refused this request because the request entity is in a format not supported by the requested resource for the requested method (Unsupported Media Type)".&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;My request object:&lt;/SPAN&gt;&lt;/P&gt;&lt;PRE&gt;this.RequestFormat = DataFormat.Json;
this.AddUrlSegment("id", workspaceId.ToString());
this.AddUrlSegment("dmsID", itemId.ToString());
this.AddUrlSegment("fileID", fileId.ToString());
this.AddHeader("Content-Type", "application/json");&lt;/PRE&gt;&lt;P&gt;&lt;SPAN&gt;What's wrong with this transferred data?&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 30 Jun 2015 14:33:56 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/fusion-manage-forum/api-v1-rest-checkin/m-p/5699772#M6133</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2015-06-30T14:33:56Z</dc:date>
    </item>
    <item>
      <title>Re: api v1 REST checkin</title>
      <link>https://forums.autodesk.com/t5/fusion-manage-forum/api-v1-rest-checkin/m-p/5699866#M6134</link>
      <description>&lt;P&gt;Martin, thanks for the reply! But for now I have the next error message "The first part of the request should contain object information". It seems like I need to transfer object info in the body of the request. But, again, I couldn't find any information about this in specs - &lt;A href="http://help.autodesk.com/view/PLM/ENU/?guid=GUID-CB766836-98D8-4E46-BB7B-C031B4B6DCD4" target="_blank"&gt;http://help.autodesk.com/view/PLM/ENU/?guid=GUID-CB766836-98D8-4E46-BB7B-C031B4B6DCD4&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 30 Jun 2015 15:05:51 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/fusion-manage-forum/api-v1-rest-checkin/m-p/5699866#M6134</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2015-06-30T15:05:51Z</dc:date>
    </item>
    <item>
      <title>Re: api v1 REST checkin</title>
      <link>https://forums.autodesk.com/t5/fusion-manage-forum/api-v1-rest-checkin/m-p/5700486#M6135</link>
      <description>&lt;P&gt;&lt;SPAN&gt;Greetings,&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;The URL for checkins is different than for creating/uploading initial attachments, but the payload structure is the same as in create attachments or add binary file into an image field type on itemdetails. Please review this link. &lt;A href="http://help.autodesk.com/view/PLM/ENU/?guid=GUID-F31EF246-A5EA-4892-B188-AA3F11DE4DBB" target="_blank"&gt;http://help.autodesk.com/view/PLM/ENU/?guid=GUID-F31EF246-A5EA-4892-B188-AA3F11DE4DBB&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Here, the code is missing a payload for the application/json part.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE class="pre codeblock prettyprint prettyprinted"&gt;&lt;SPAN class="pun"&gt;{&lt;/SPAN&gt;
   &lt;SPAN class="str"&gt;"fileName"&lt;/SPAN&gt;&lt;SPAN class="pun"&gt;:&lt;/SPAN&gt;&lt;SPAN class="str"&gt;"{FileName}"&lt;/SPAN&gt;&lt;SPAN class="pun"&gt;,&lt;/SPAN&gt;
   &lt;SPAN class="str"&gt;"resourceName"&lt;/SPAN&gt;&lt;SPAN class="pun"&gt;:&lt;/SPAN&gt;&lt;SPAN class="str"&gt;"{UniqueResourceName}"&lt;/SPAN&gt;&lt;SPAN class="pun"&gt;,&lt;/SPAN&gt;
   &lt;SPAN class="str"&gt;"description"&lt;/SPAN&gt;&lt;SPAN class="pun"&gt;:&lt;/SPAN&gt;&lt;SPAN class="str"&gt;"{FileDescription}"&lt;/SPAN&gt;
&lt;SPAN class="pun"&gt;}&lt;/SPAN&gt;&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;Also missing is a header on the entire http call&amp;nbsp;"Content-Type: multipart/mixed" as well as the second part of the payload being binary including a Content-Disposition header and specific fields like "key" mandatory. &amp;nbsp;Please take a look at this dealing with adding a binary file to field of type Image for a complete example.&amp;nbsp;&lt;A href="http://help.autodesk.com/view/PLM/ENU/?guid=GUID-D189F997-B297-4C83-A249-B4A5F3671E39" target="_blank"&gt;http://help.autodesk.com/view/PLM/ENU/?guid=GUID-D189F997-B297-4C83-A249-B4A5F3671E39&lt;/A&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;Hope this helps,&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 30 Jun 2015 19:44:01 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/fusion-manage-forum/api-v1-rest-checkin/m-p/5700486#M6135</guid>
      <dc:creator>gasevsm</dc:creator>
      <dc:date>2015-06-30T19:44:01Z</dc:date>
    </item>
    <item>
      <title>Re: api v1 REST checkin</title>
      <link>https://forums.autodesk.com/t5/fusion-manage-forum/api-v1-rest-checkin/m-p/5729514#M6136</link>
      <description>&lt;P&gt;I am also trying to checkin files via the v1 api. I have read the above but am still getting a 500 - Internal Server error. Is there any possible way to post a curl example as many of the help files show?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Nick&lt;/P&gt;</description>
      <pubDate>Mon, 20 Jul 2015 19:29:57 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/fusion-manage-forum/api-v1-rest-checkin/m-p/5729514#M6136</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2015-07-20T19:29:57Z</dc:date>
    </item>
    <item>
      <title>Re: api v1 REST checkin</title>
      <link>https://forums.autodesk.com/t5/fusion-manage-forum/api-v1-rest-checkin/m-p/5741031#M6137</link>
      <description>&lt;P&gt;Hi, Nick. Just do 'check out' &amp;amp; 'undo check out' operations because attachments are marked as "checked in" by default after upload.&amp;nbsp;&lt;SPAN&gt;This works for me.&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Sun, 26 Jul 2015 17:51:47 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/fusion-manage-forum/api-v1-rest-checkin/m-p/5741031#M6137</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2015-07-26T17:51:47Z</dc:date>
    </item>
    <item>
      <title>Re: api v1 REST checkin</title>
      <link>https://forums.autodesk.com/t5/fusion-manage-forum/api-v1-rest-checkin/m-p/5741879#M6138</link>
      <description>&lt;P&gt;I just tried to do a 'checkout,' change my file contents, then a 'create an attachment' for the same file and then an 'undo checkout.' I think this process did exactly what I would expect in that the checkout was taken away but the file contents were not updated so the attached file was the same as it was before the 'checkout' was performed. Is that the same for you? I would think that I would have to successfully complete a 'checkin' for the file to be updated.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I have tried to do the 'checkin' by creating the multipart/mixed request with the json as the first part and the second part being the file binary data. I do this via curl:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;curl -v -k -i -X POST \
-H "Content-Type: multipart/mixed" \
-H "Accept: application/json" -H "Cookie: customer=&amp;lt;customer&amp;gt;; JSESSIONID=&amp;lt;sessionid&amp;gt;;" \
-F "metadata=@file.json; type=application/json" \
-F "content=@'document.pdf'; type=application/octet-stream" \
https://&amp;lt;tenant&amp;gt;.autodeskplm360.net/api/rest/v1/workspaces/22/items/14305/attachments/16/checkins' &lt;/PRE&gt;&lt;P&gt;with the file.json being:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;{
   "fileName":"document.pdf",
   "resourceName":"document.pdf",
   "description":"Test Document"
}&lt;/PRE&gt;&lt;P&gt;This returns a 500 - Internal Server Error:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;HTTP/1.1 500 Internal Server Error
Date: Mon, 27 Jul 2015 14:04:47 GMT
Server: Apache
Set-Cookie: PLM360LBR=cookie==; path=/; domain=tenant.autodeskplm360.net
Vary: Cookie,Host,Accept-Encoding
Cache-Control: no-cache
Access-Control-Expose-Headers: X-AUTODESK-URI-ENCODING
Content-Length: 154
X-Frame-Options: SAMEORIGIN
Strict-Transport-Security: max-age=31536000; includeSubDomains; preload
X-XSS-Protection: 1; mode=block
Connection: close
Content-Type: application/xml

&amp;lt;?xml version="1.0" encoding="UTF-8" standalone="yes"?&amp;gt;&amp;lt;errors xmlns:ns2="http://ns.autodesk.com/storage/v1"&amp;gt;&amp;lt;httpStatusCode&amp;gt;500&amp;lt;/httpStatusCode&amp;gt;&amp;lt;/errors&amp;gt;&lt;/PRE&gt;&lt;P&gt;Any help is appreciated.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Nick&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 27 Jul 2015 14:06:38 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/fusion-manage-forum/api-v1-rest-checkin/m-p/5741879#M6138</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2015-07-27T14:06:38Z</dc:date>
    </item>
    <item>
      <title>Re: api v1 REST checkin</title>
      <link>https://forums.autodesk.com/t5/fusion-manage-forum/api-v1-rest-checkin/m-p/5753623#M6139</link>
      <description>&lt;P&gt;Hi, Nick. Yeah, I think that problem with 'check in' wasn't solved because it didn't work for me too as I want. I figured this problem out with replace 'check in' operation with the next two:&lt;BR /&gt;1) Delete an attachment&lt;BR /&gt;2) Create an attachment&lt;BR /&gt;Hope, this helps.&lt;/P&gt;</description>
      <pubDate>Mon, 03 Aug 2015 07:16:14 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/fusion-manage-forum/api-v1-rest-checkin/m-p/5753623#M6139</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2015-08-03T07:16:14Z</dc:date>
    </item>
    <item>
      <title>Re: api v1 REST checkin</title>
      <link>https://forums.autodesk.com/t5/fusion-manage-forum/api-v1-rest-checkin/m-p/5757203#M6140</link>
      <description>&lt;P&gt;While I agree that the deleting and replacing an attachment will update the file, it unfortunately also makes the change log of my workspace item not completely accurate. I also am unsure what would happen to the attachment version history. As this is important to the traceability of my workspace, the deleting and re-attaching method is not a perfect solution. Thanks for the suggestion though.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I have continued to try and make the check in work still with no success. Any other information or advice is appreciated.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Nick&lt;/P&gt;</description>
      <pubDate>Wed, 05 Aug 2015 02:38:41 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/fusion-manage-forum/api-v1-rest-checkin/m-p/5757203#M6140</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2015-08-05T02:38:41Z</dc:date>
    </item>
    <item>
      <title>Re: api v1 REST checkin</title>
      <link>https://forums.autodesk.com/t5/fusion-manage-forum/api-v1-rest-checkin/m-p/5771245#M6141</link>
      <description>&lt;P&gt;We have been working on making use of the checkout/checkin API recently and have managed to get it working so I thought I'd share our insights with this thread.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;It turns out that the "checkins" API method payload isn't quite the same as the one for a new attachment, it's missing a&amp;nbsp;fileVersion:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;{
   "fileName":"{FileName}",
   "resourceName":"{UniqueResourceName}",
   "description":"{FileDescription}"
   "fileVersion":"{FileVersion}"
}&lt;/PRE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The first checkin of a file doesn't require this so we guess the API defaults it to 1 if it's missing.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Otherwise, setting up the request just as Martin describes in his post on 30th June worked just fine for us.&lt;/P&gt;</description>
      <pubDate>Fri, 14 Aug 2015 10:04:09 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/fusion-manage-forum/api-v1-rest-checkin/m-p/5771245#M6141</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2015-08-14T10:04:09Z</dc:date>
    </item>
    <item>
      <title>Re: api v1 REST checkin</title>
      <link>https://forums.autodesk.com/t5/fusion-manage-forum/api-v1-rest-checkin/m-p/5771435#M6142</link>
      <description>&lt;P&gt;Excellent job! This works perfectly. Thanks!&lt;/P&gt;</description>
      <pubDate>Fri, 14 Aug 2015 13:04:17 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/fusion-manage-forum/api-v1-rest-checkin/m-p/5771435#M6142</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2015-08-14T13:04:17Z</dc:date>
    </item>
    <item>
      <title>Re: api v1 REST checkin</title>
      <link>https://forums.autodesk.com/t5/fusion-manage-forum/api-v1-rest-checkin/m-p/5772195#M6143</link>
      <description>&lt;P&gt;Greetings.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Please refer to this article as there a fix that you may be looking for. &amp;nbsp;Seems tho threads interested in same topic, so I'm unifying&amp;nbsp;the audience and interested parties. &amp;nbsp;Kudos to @Anonymous﻿&amp;nbsp;and his development team for discovering the fileVersion missing default behavior~!&lt;/P&gt;
&lt;P&gt;Hope this helps,&lt;/P&gt;</description>
      <pubDate>Fri, 14 Aug 2015 19:59:27 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/fusion-manage-forum/api-v1-rest-checkin/m-p/5772195#M6143</guid>
      <dc:creator>gasevsm</dc:creator>
      <dc:date>2015-08-14T19:59:27Z</dc:date>
    </item>
  </channel>
</rss>

