<?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: iOS Objective C. up/download URL. in Dropbox API Support &amp; Feedback</title>
    <link>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/iOS-Objective-C-up-download-URL/m-p/208783#M10323</link>
    <description>&lt;P&gt;It sounds like you're referring to &lt;A href="https://dropbox.github.io/dropbox-sdk-obj-c/api-docs/latest/Classes/DBFILESRoutes.html#/c:objc(cs)DBFILESRoutes(im)uploadUrl:inputUrl:" target="_self"&gt;uploadUrl&lt;/A&gt; and &lt;A href="https://dropbox.github.io/dropbox-sdk-obj-c/api-docs/latest/Classes/DBFILESRoutes.html#/c:objc(cs)DBFILESRoutes(im)downloadUrl:overwrite:destination:" target="_self"&gt;downloadUrl&lt;/A&gt;. The documentation there has more information, but the first parameter to each is the remote path in&amp;nbsp;Dropbox (that is, the path where you want to upload to or download from, respectively.) The URL parameter is likewise the file URL to upload from or download to, respectively.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Here are some examples of what those would look like:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;[[client.filesRoutes uploadUrl:@"/test.txt" inputUrl:[NSURL fileURLWithPath:@"/local/path/to/test.txt"]]
 setResponseBlock:^(DBFILESFileMetadata *metadata, DBFILESUploadError *uploadError, DBRequestError *error) {
    if (metadata) {
        NSLog(@"The upload completed successfully.");
        NSLog(@"File metadata:");
        NSLog(@"%@", metadata);
    } else if (uploadError) {
        NSLog(@"Something went wrong with the upload:");
        NSLog(@"%@", uploadError);
    } else if (error) {
        NSLog(@"Something went wrong with the API call:");
        NSLog(@"%@", error);
    }
}];&lt;/PRE&gt;
&lt;PRE&gt;[[client.filesRoutes downloadUrl:@"/test.txt" overwrite:true destination:[NSURL fileURLWithPath:@"/local/path/to/test.txt"]]
 setResponseBlock:^(DBFILESFileMetadata *metadata, DBFILESDownloadError *downloadError, DBRequestError *error, NSURL *destination) {
         if (metadata) {
             NSLog(@"The download call completed successfully.");
             NSLog(@"File metadata:");
             NSLog(@"%@", metadata);
         } else if (downloadError) {
             NSLog(@"Something went wrong with the download:");
             NSLog(@"%@", downloadError);
         } else if (error) {
             NSLog(@"Something went wrong with the API call:");
             NSLog(@"%@", error);
         }
 }];&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;If this isn't working for you, can you share the code that isn't working for you and the error you're getting?&lt;/P&gt;</description>
    <pubDate>Mon, 27 Feb 2017 19:35:18 GMT</pubDate>
    <dc:creator>Greg-DB</dc:creator>
    <dc:date>2017-02-27T19:35:18Z</dc:date>
    <item>
      <title>iOS Objective C. up/download URL.</title>
      <link>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/iOS-Objective-C-up-download-URL/m-p/208779#M10321</link>
      <description>&lt;P&gt;I can't seem to get the right response block for these. A little Help?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Also one parameter is labeled as a URL but takes a string, which I assume is a path.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Your web page examples on file transfers&amp;nbsp;are in sore need of being updated.&lt;/P&gt;</description>
      <pubDate>Wed, 29 May 2019 09:25:24 GMT</pubDate>
      <guid>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/iOS-Objective-C-up-download-URL/m-p/208779#M10321</guid>
      <dc:creator>AppleGG</dc:creator>
      <dc:date>2019-05-29T09:25:24Z</dc:date>
    </item>
    <item>
      <title>Re: iOS Objective C. up/download URL.</title>
      <link>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/iOS-Objective-C-up-download-URL/m-p/208783#M10323</link>
      <description>&lt;P&gt;It sounds like you're referring to &lt;A href="https://dropbox.github.io/dropbox-sdk-obj-c/api-docs/latest/Classes/DBFILESRoutes.html#/c:objc(cs)DBFILESRoutes(im)uploadUrl:inputUrl:" target="_self"&gt;uploadUrl&lt;/A&gt; and &lt;A href="https://dropbox.github.io/dropbox-sdk-obj-c/api-docs/latest/Classes/DBFILESRoutes.html#/c:objc(cs)DBFILESRoutes(im)downloadUrl:overwrite:destination:" target="_self"&gt;downloadUrl&lt;/A&gt;. The documentation there has more information, but the first parameter to each is the remote path in&amp;nbsp;Dropbox (that is, the path where you want to upload to or download from, respectively.) The URL parameter is likewise the file URL to upload from or download to, respectively.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Here are some examples of what those would look like:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;[[client.filesRoutes uploadUrl:@"/test.txt" inputUrl:[NSURL fileURLWithPath:@"/local/path/to/test.txt"]]
 setResponseBlock:^(DBFILESFileMetadata *metadata, DBFILESUploadError *uploadError, DBRequestError *error) {
    if (metadata) {
        NSLog(@"The upload completed successfully.");
        NSLog(@"File metadata:");
        NSLog(@"%@", metadata);
    } else if (uploadError) {
        NSLog(@"Something went wrong with the upload:");
        NSLog(@"%@", uploadError);
    } else if (error) {
        NSLog(@"Something went wrong with the API call:");
        NSLog(@"%@", error);
    }
}];&lt;/PRE&gt;
&lt;PRE&gt;[[client.filesRoutes downloadUrl:@"/test.txt" overwrite:true destination:[NSURL fileURLWithPath:@"/local/path/to/test.txt"]]
 setResponseBlock:^(DBFILESFileMetadata *metadata, DBFILESDownloadError *downloadError, DBRequestError *error, NSURL *destination) {
         if (metadata) {
             NSLog(@"The download call completed successfully.");
             NSLog(@"File metadata:");
             NSLog(@"%@", metadata);
         } else if (downloadError) {
             NSLog(@"Something went wrong with the download:");
             NSLog(@"%@", downloadError);
         } else if (error) {
             NSLog(@"Something went wrong with the API call:");
             NSLog(@"%@", error);
         }
 }];&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;If this isn't working for you, can you share the code that isn't working for you and the error you're getting?&lt;/P&gt;</description>
      <pubDate>Mon, 27 Feb 2017 19:35:18 GMT</pubDate>
      <guid>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/iOS-Objective-C-up-download-URL/m-p/208783#M10323</guid>
      <dc:creator>Greg-DB</dc:creator>
      <dc:date>2017-02-27T19:35:18Z</dc:date>
    </item>
    <item>
      <title>Re: iOS Objective C. up/download URL.</title>
      <link>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/iOS-Objective-C-up-download-URL/m-p/237536#M13123</link>
      <description>&lt;P&gt;Hey,&lt;/P&gt;&lt;P&gt;Your example contains:&lt;/P&gt;&lt;PRE&gt;inputUrl:[NSURL fileURLWithPath:@"/local/path/to/test.txt"&lt;/PRE&gt;&lt;P&gt;But when you check DBFILESUserAuthRoutes, there's :&lt;/P&gt;&lt;P&gt;- (DBUploadTask *)uploadUrl:(NSString *)path inputUrl:(&lt;STRONG&gt;NSString&lt;/STRONG&gt; *)inputUrl&lt;/P&gt;&lt;P&gt;So, the inputUrl argument is an NSString, not NSURL type.&lt;/P&gt;&lt;P&gt;Moreover, uploadUrl calls requestUpload, where the inputUrl (named as input) is converted to NSURL:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;- (DBUploadTaskImpl *)requestUpload:(DBRoute *)route arg:(id&amp;lt;DBSerializable&amp;gt;)arg inputUrl:(&lt;STRONG&gt;NSString&lt;/STRONG&gt; *)input {&lt;BR /&gt;&amp;nbsp;&lt;STRONG&gt; NSURL *inputUrl = [NSURL fileURLWithPath:input];&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;So, reasuming. Direct file path ( NSString*) should be passed to uploadUrl,&amp;nbsp; not the URL.&lt;/P&gt;&lt;P&gt;The "inputUrl" name is also misleading (probably leftover from previous version??),&amp;nbsp; should be inputPath, so&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;inputUrl:(NSURL *)inputUrl&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;or&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;inputPath:(NSString *)inputUrl&amp;nbsp;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Would be much better.&lt;/P&gt;&lt;P&gt;The same problem is with other args with "Url" in name abd NSString* type.&lt;/P&gt;</description>
      <pubDate>Fri, 18 Aug 2017 09:49:18 GMT</pubDate>
      <guid>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/iOS-Objective-C-up-download-URL/m-p/237536#M13123</guid>
      <dc:creator>tslanina</dc:creator>
      <dc:date>2017-08-18T09:49:18Z</dc:date>
    </item>
    <item>
      <title>Re: iOS Objective C. up/download URL.</title>
      <link>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/iOS-Objective-C-up-download-URL/m-p/237580#M13128</link>
      <description>&lt;P&gt;&lt;a href="https://www.dropboxforum.com/t5/user/viewprofilepage/user-id/465733"&gt;@tslanina&lt;/a&gt;&amp;nbsp;That's correct, these NSURL parameters were changed to NSString in &lt;A href="https://github.com/dropbox/dropbox-sdk-obj-c/releases/tag/3.0.11" target="_self"&gt;v3.0.11&lt;/A&gt; after I wrote the examples above.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I'll send this along to the team&amp;nbsp;as a request to update the method/parameter names to clarify.&lt;/P&gt;</description>
      <pubDate>Fri, 18 Aug 2017 14:20:38 GMT</pubDate>
      <guid>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/iOS-Objective-C-up-download-URL/m-p/237580#M13128</guid>
      <dc:creator>Greg-DB</dc:creator>
      <dc:date>2017-08-18T14:20:38Z</dc:date>
    </item>
    <item>
      <title>Re: iOS Objective C. up/download URL.</title>
      <link>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/iOS-Objective-C-up-download-URL/m-p/316554#M18783</link>
      <description>&lt;P&gt;I'm getting an "unrecognized selector sent to instance" for uploadURL. Trying to update to newest SDK from the old one that supported iOS 8. &amp;nbsp;Those links you posted are broken. &amp;nbsp;Is uploadURL gone? &amp;nbsp;What's its replacement???&lt;/P&gt;</description>
      <pubDate>Sat, 08 Dec 2018 18:22:14 GMT</pubDate>
      <guid>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/iOS-Objective-C-up-download-URL/m-p/316554#M18783</guid>
      <dc:creator>Bob S.15</dc:creator>
      <dc:date>2018-12-08T18:22:14Z</dc:date>
    </item>
    <item>
      <title>Re: iOS Objective C. up/download URL.</title>
      <link>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/iOS-Objective-C-up-download-URL/m-p/316934#M18796</link>
      <description>&lt;P&gt;&lt;a href="https://www.dropboxforum.com/t5/user/viewprofilepage/user-id/49312"&gt;@Bob S.15&lt;/a&gt;&amp;nbsp;I see you opened a new thread for this, so I'll follow up there:&lt;/P&gt;
&lt;P&gt;&lt;A href="https://www.dropboxforum.com/t5/API-Support-Feedback/uploadURL-unrecognized-selector/m-p/316559#M18784&amp;nbsp;" target="_blank"&gt;https://www.dropboxforum.com/t5/API-Support-Feedback/uploadURL-unrecognized-selector/m-p/316559#M18784&amp;nbsp;&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 10 Dec 2018 17:58:42 GMT</pubDate>
      <guid>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/iOS-Objective-C-up-download-URL/m-p/316934#M18796</guid>
      <dc:creator>Greg-DB</dc:creator>
      <dc:date>2018-12-10T17:58:42Z</dc:date>
    </item>
  </channel>
</rss>

