GET URL link from uploaded image to dropbox with SDK

后端 未结 1 1673
醉梦人生
醉梦人生 2020-12-21 14:34

Uploading images to a folder using the SDK I would like to get the original link to the image. I have searched the the metaData from DMMetaData using the method below. Ther

相关标签:
1条回答
  • 2020-12-21 14:55

    To get a sharable link for a file in DropBox !

    There is a method in DBRestClient.h that you should take a look at!

    - (void)loadSharableLinkForFile:(NSString *)path;
    

    and their delegate Methods as well!!

    - (void)restClient:(DBRestClient*)restClient loadedSharableLink:(NSString*)link 
    forFile:(NSString*)path;
    - (void)restClient:(DBRestClient*)restClient loadSharableLinkFailedWithError:(NSError*)error;
    

    example : let us consider i have a file MyContacts in my Dropbox then to share it ,

    [[self restClient] loadSharableLinkForFile:@"/MyContacts"];
    

    and their delegate methods

    - (void)restClient:(DBRestClient*)restClient loadedSharableLink:(NSString*)link 
               forFile:(NSString*)path
    {
    
        NSLog(@"Sharable link %@",link);
        NSLog(@"File Path %@ ",path);
    }
    
    - (void)restClient:(DBRestClient*)restClient loadSharableLinkFailedWithError:(NSError*)error
    {
        NSLog(@"Error %@",error);
    }
    
    0 讨论(0)
提交回复
热议问题