This repository has been archived by the owner on Dec 18, 2022. It is now read-only.
-
-
Notifications
You must be signed in to change notification settings - Fork 20
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
3ce3871
commit 04084fa
Showing
10 changed files
with
120 additions
and
59 deletions.
There are no files selected for viewing
21 changes: 15 additions & 6 deletions
21
Example/Pods/Pods.xcodeproj/xcshareddata/xcschemes/SnapchatKit.xcscheme
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -217,6 +217,9 @@ int main(int argc, const char * argv[]) { | |
// Cannot seem to "solve" a captcha. | ||
// registerAccount(@"[email protected]", @"12345678h", @"1995-08-01"); | ||
|
||
[SKClient sharedClient].casperAPIKey = kCasperAPIKey; | ||
[SKClient sharedClient].casperAPISecret = kCasperAPISecret; | ||
|
||
[[SKClient sharedClient] signInWithUsername:kUsername password:kPassword gmail:kGmail gpass:kGmailPassword completion:^(NSDictionary *dict, NSError *error) { | ||
if (!error) { | ||
SKSession *session = [SKClient sharedClient].currentSession; | ||
|
@@ -245,19 +248,18 @@ int main(int argc, const char * argv[]) { | |
NSArray *unread = session.unread; | ||
SKLog(@"%lu unread snaps: %@", unread.count, unread); | ||
|
||
id foo = [dict[@"updates_response"] allKeys]; | ||
|
||
SKStoryCollection *friend = [[SKClient sharedClient].currentSession.stories | ||
filteredOrderedSetUsingPredicate:[NSPredicate predicateWithFormat:@"%K BEGINSWITH %@", @"displayName", @""]].firstObject; | ||
for (SKStory *s in friend.stories) | ||
[s load:^(NSError *error1) { | ||
if (!error1) { | ||
NSLog(@"Saving %@: %@", SKStringFromMediaKind(s.mediaKind), s.suggestedFilename); | ||
[s.blob writeToPath:[directory stringByAppendingString:@"/Test-download"] filename:s.suggestedFilename atomically:YES]; | ||
} else { | ||
NSLog(@"Error loading %@: %@", SKStringFromMediaKind(s.mediaKind), error1.localizedDescription); | ||
} | ||
}]; | ||
// | ||
// SKStoryCollection *friend = [[SKClient sharedClient].currentSession.stories | ||
// filteredOrderedSetUsingPredicate:[NSPredicate predicateWithFormat:@"%K BEGINSWITH %@", @"displayName", @""]].firstObject; | ||
// for (SKStory *s in friend.stories) | ||
// [s load:^(NSError *error1) { | ||
// if (!error1) { | ||
// NSLog(@"Saving %@: %@", SKStringFromMediaKind(s.mediaKind), s.suggestedFilename); | ||
// [s.blob writeToPath:[directory stringByAppendingString:@"/Test-download"] filename:s.suggestedFilename atomically:YES]; | ||
// } else { | ||
// NSLog(@"Error loading %@: %@", SKStringFromMediaKind(s.mediaKind), error1.localizedDescription); | ||
// } | ||
// }]; | ||
|
||
|
||
// [[SKClient sharedClient] get:[NSString stringWithFormat:@"%@US", kepDiscoverChannels] callback:^(id object, NSError *error) { | ||
|
@@ -297,7 +299,7 @@ int main(int argc, const char * argv[]) { | |
// testGetConversations(); | ||
|
||
// Download and save unread snaps | ||
saveUnreadSnapsToDirectory(unread, directory); | ||
// saveUnreadSnapsToDirectory(unread, directory); | ||
|
||
// Mark snaps read | ||
// markSnapsRead(unread); | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.