Hi there,
I’m a new to Estimote and am currently trying to map a space with the Location Builder. I’m getting an error when I try and save the location to the cloud. The error is as follows:
**2018-04-14 21:42:53.586094+0100 SpaceConfig[3445:1243231] Error when saving location: Error Domain=ESTRequestBaseErrorDomain Code=403 "You have no access to the requested resource." UserInfo={NSLocalizedDescription=You have no access to the requested resource., NSLocalizedRecoverySuggestion=Verify if requested resource belongs to you.}**
I was hoping someone could shed some light on what this error means? I’m working in my App Delegate (following these instructions). My code is below.
- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions {
// Override point for customization after application launch.
EILLocationBuilder *locationBuilder = [EILLocationBuilder new];
[locationBuilder setLocationName:@"Sarah's bedroom"];
[locationBuilder setLocationBoundaryPoints:@[[EILPoint pointWithX:0.00 y:0.00],
[EILPoint pointWithX:0.00 y:4.36],
[EILPoint pointWithX:5.00 y:4.36],
[EILPoint pointWithX:5.00 y:0.00]]];
[locationBuilder addBeaconWithIdentifier:@"beacon1" // beetroot
atBoundarySegmentIndex:0
inDistance:1.4 fromSide:EILLocationBuilderLeftSide];
[locationBuilder addBeaconWithIdentifier:@"beacon2" // lemon
atBoundarySegmentIndex:1
inDistance:1.8 fromSide:EILLocationBuilderLeftSide];
[locationBuilder addBeaconWithIdentifier:@"beacon3" // candy
atBoundarySegmentIndex:2
inDistance:1.8 fromSide:EILLocationBuilderRightSide];
[locationBuilder setLocationOrientation:278];
EILLocation *location = [locationBuilder build];
[ESTConfig setupAppID:@"<App ID>" andAppToken:@"<App Token>"];
EILRequestAddLocation *addLocationRequest = [[EILRequestAddLocation alloc] initWithLocation:location];
[addLocationRequest sendRequestWithCompletion:^(EILLocation *location, NSError *error) {
if (error) {
NSLog(@"Error when saving location: %@", error);
} else {
NSLog(@"Location saved successfully: %@", location.identifier);
}
}];
return YES;
}
Really can’t seem to figure this one so any help would be greatly, greatly appreciated! Thank you.