arrow-left

All pages
gitbookPowered by GitBook
1 of 1

Loading...

Error Codes

Here is a list of the error codes that the Cortex API can return. This list is not exhaustive (yet) and will be updated in the future.

hashtag
-32700 Parse Error

The message you sent to Cortex is not a valid JSON objectarrow-up-right. This is a bug is your application.

hashtag
-32600 Invalid Request

The message you sent to Cortex is a valid JSON object but it doesn't contain the expected fields. This a bug is your application. Please check

hashtag
-32601 Method Not Found

You sent a request with an invalid method name. This a bug is your application. Please check this documentation to see which methods are available.

hashtag
-32602 Invalid Parameters

You sent a request to call a valid method, but the parameters are wrong. It can be because:

  • You didn't provide a required parameter

  • You provided a parameters with an invalid name

  • The name of parameter is correct but the value is invalid

This is a bug in your application. Please check the documentation of the method.

hashtag
-32603 Internal Error

An unexpected error happened in Cortex while processing your request. This is probably a bug in Cortex. If the problem persists, please contact the .

hashtag
-32000 Server Internal Error

An unexpected error happened in the EMOTIV cloud while processing your request. It can be a temporary failure of the EMOTIV servers, like when the servers are in maintenance. Or it can be a bug in Cortex. If the problem persists, please contact the .

hashtag
-32002 Invalid License ID

The EMOTIV cloud cannot find the license of the user. When you call the method , please make sure that you provide a valid license ID, or no license parameter at all. If the problem persists, then the owner of the license must contact the .

hashtag
-32003 Internet Connection Error

Cortex must connect to the EMOTIV cloud to process your request, but the connection failed. Please make sure that you computer has a working internet connection. Please make sure your internet is not blocked by any firewall or security, see .

hashtag
-32004 Headset Unavailable

You sent a request to perform an action on a specific headset, but Cortex cannot find this headset. Some possible reasons for this error:

  • You provided an invalid headset ID in your request

  • The headset was disconnected (maybe it is out of range of your computer)

  • The headset was switched off

hashtag
-32005 A session already exists with this headset

You called the method for a specific headset, but your application already has a session for this headset. This is a bug in your application. You cannot create 2 sessions for the same headset at the same time. You must the existing session before creating a new one.

hashtag
-32006 No license to activate a session

You called or with the parameter "status" set to "active", but your license doesn't authorize you to activate a session. You have a paid EMOTIV license to activate a session. If you already have such a license but the problem still persists, then contact the . You should also read the .

hashtag
-32007 The session doesn't exist

You included a session ID in the parameters of your request, but Cortex cannot find this session. It can be because you session ID is invalid or because the session is already closed.

Many methods can return this error: , , , , , , etc...

hashtag
-32012 The session must be activated

You called a method that requires an active session, but the current session is inactive. It can happen if you call on an inactive session.

hashtag
-32014 Invalid Cortex token

You included a Cortex token in the parameters of your request, but this token is invalid. This is a bug in your application. When a method requires a Cortex token, please make sure that your token comes from the result of the method .

hashtag
-32015 The Cortex token has expired

Your Cortex token has expired. You must call the method again to get a new token. The Cortex token is valid for 48 hours.

The requires Internet access. If you want your app to stay offline for longer time, you should call to generate a new token from the expired token.

hashtag
-32016 Invalid stream

You called the methods or with an invalid stream. The stream can be invalid for one of these reasons:

  • The name of the stream is incorrect. Check for the list of the available streams.

  • The stream is not available for this headset. For example, the motion data of an EPOC X headset can be disable.

  • The stream is "eeg" but the license doesn't allow you to access this stream. You can check the license with

hashtag
-32017 Record already started

You called for a specific session, but your application already started a record for the same session. You cannot create 2 records for the same session at the same time.

hashtag
-32019 Session limit has been reached

You tried to activate a session (with or ) but the "localQuota" of the license is zero. You can check the "localQuota" by calling the method . Every time you activate a session, the local quota of the license is reduced by 1.

To solve this error, you must increase the local quota of the license. Call with the parameter "debit". For example, you can call with a "debit" of 10, and this will increase the local quota by 10. Then you will be able to create and activate 10 sessions on this computer.

hashtag
-32020 The headset must be connected with a USB cable

You called but the headset is connected to the computer via Bluetooth or a USB dongle. Instead, the user should connect the headset with a USB cable.

hashtag
-32021 Invalid client credentials

The error indicates that your request includes an invalid client ID or client secret. Ensure your request contains a valid client ID and client secret. You can obtain these credentials by registering your App ID with the Cortex SDK for development according to the .

hashtag
-32022 Device limit has been reached

The license was used on too many devices (eg computer, tablet, phone...). The license has a device limit. You can check it by calling the method . If you want to increase the limit or transfer the license from 1 device to another, then please contact the .

hashtag
-32024 The license has expired

The license of the user has expired. You can check the license with . After the license is renewed, your application must call to get a new token.

hashtag
-32027 Cannot use this license

You called with a valid license ID but your application doesn't have the permission to use this license.

hashtag
-32029 License hard limit has been reached

When the computer is offline, you can use the license for a limited period of time. The end of this period is the "hard limit" of the license. You can check it with . After the "hard limit" has been reached, Cortex must connect to the EMOTIV cloud to validate the license again. To solve this problem, the computer must have an internet connection and then you must call .

hashtag
-32031 Invalid profile name

You sent a request to perform an action on a specific , but Cortex cannot find this profile.

hashtag
-32032 Multi Emotiv ID user

You can got this error when call login while there is already a EmotivID user logged in. Before login in, you should check if there is logged in EmotivID user via getUserLogin API.

This error is only available on Cortex version which support login API (for example: Cortex embedded lib).

hashtag
-32033 EmotivID user is not logged in

Cortex cannot process your request because no EmotivID user is logged in.

For the Cortex websocket server, you must ask the user to log in in .

For other Cortex version which supports login, you must call login first.

hashtag
-32034 The Cortex token is for another user

Your request includes a Cortex token that was created for a specific user, but the current user is a different one. In that case, that must call again and get a new token. You can check the current user with .

hashtag
-32035 EmotivID is not matching with logged in user

You will get this issue if the username is not the same with currently logged in EmotivID user.

Related API are logout. This API is only available for the Cortex embedded lib.

hashtag
-32037 Cannot train this action

You called for an action that cannot be trained. Please see available actions .

hashtag
-32044 Profile already loaded on another headset

You tried to a training profile for a specific headset, but this profile is already loaded for another headset. You cannot load the same profile on 2 different headset at the same time.

hashtag
-32045 No profile loaded for this headset

You tried to unload a training profile from a headset, but no profile was loaded for this headset.

hashtag
-32046 Profile loaded by another application

You tried to perform an operation (eg , ...) on a training profile, but this profile was loaded by another application. An application can only access a profile that loaded by itself. You can call to check if your application loaded the profile of a headset or not.

hashtag
-32102 Not approved in EMOTIV Launcher

The user didn't approved your application yet. The user must open and approve your application.

hashtag
-32104 Failed to connect or disconnect the headset

Cortex failed to communicate with the headset. Maybe the wireless connection between the headset and the computer was interrupted. Your application should try again. You can also call to check the status of the headset.

hashtag
-32106 The user account is not active

The EMOTIV ID of the user is inactive. The app will get this error when the user has registered the EmotivID account but haven't activated via email yet.

hashtag
-32107 Cannot accept license agreement

If you got this error when calling acceptLicense API, there is a bug in our Cortex or Emotiv Cloud. Please report this issue to .

This acceptLicense is only available on the Cortex embedded lib.

hashtag
-32108 Cloud token error

The EMOTIV cloud refused the user credentials provided by Cortex. The user must logout and login again.

hashtag
-32109 Cortex token error

There is something wrong with the Cortex token. Your application must call to get a new Cortex token.

hashtag
-32111 The information cannot be found in database

For APIs that need information from the local database, if Cortex cannot find this information in the database, this error is returned. This error is general and can be returned for any API. If the problem persists, please contact .

hashtag
-32112 The session is already active

You tried to a session that is already active. You can call to check the status of your sessions.

hashtag
-32113 Invalid record ID

You are trying to access a record that doesn't exist, or the record exist but you don't have the permission to access it.

hashtag
-32114 No record in progress

You are trying to a marker or to a record but no record is is progress.

hashtag
-32115 The time of the marker is too far in the past

You are trying to inject a marker but its time is too far in the past. You should inject your markers in real time, at the moment the event you want to mark happens.

Sometimes you may get the issue because the difference between the time system in your app and the headset time system in Cortex is considerable. In this case, to have better synchronization with the headset time system, please use the API.

hashtag
-32116 The time of the marker is too far in the future

You are trying to inject a marker but its time is too far in the future. You should inject your markers in real time, at the moment the event you want to mark happens.

Sometimes you may get the issue because the difference between the time system in your app and the headset time system in Cortex is considerable. In this case, to have better synchronization with the headset time system, please use the API.

hashtag
-32117 Marker not found

You called with an invalid marker id.

hashtag
-32118 The profile name already exists

You are trying to or rename a training profile, but another profile with the same name already exists.

hashtag
-32119 The marker is already stopped

You are trying to a marker that was already updated before.

hashtag
-32120 headset mapping config name already exists

The error can occur if you use an existing mapping name while creating a new mapping with the API.

hashtag
-32121 The flex config was not found.

This error occurs when you use a non-existent EPOC Flex mapping UUID or name while calling the or API.

hashtag
-32122 Cortex is starting

The app will get this error sometimes after the app connection is established to Cortex web socket server or after the app call CortexLib::start() API of the Cortex embedded lib, when it takes long for Cortex to be ready, especially when Cortex needs to do some database upgrading. In this case, the app only needs to wait for a while and remake API calls.

hashtag
-32123 Corrupted database

The local Cortex database is corrupted. Please contact the .

hashtag
-32124 Subject not found

You are trying to or a subject that doesn't exist. Or you are trying to a record with an invalid subject.

hashtag
-32125 Subject already exists

You are trying to create a subject, but another subject with the same name already exists.

hashtag
-32126 The record session is running

The app can get this error if you call on a running record. Please make sure the app calls before .

hashtag
-32127 Profile already loaded for this headset

You are trying to a training profile for a headset, but a profile was already loaded for this headset before. You must unload the current profile before loading a new one.

hashtag
-32129 Invalid record title

You are trying to create or update a record, but the record title is invalid. The title must be 200 characters long or less.

hashtag
-32130 Cloud token is being refreshed

If the Cortex API needs to work with the Emotiv Cloud (e.g: API), the app can get this issue when the cloud token is being refreshed. The app should wait until the token is refreshed and try the API call again.

hashtag
-32135 Cortex token with incorrect application id or version

The Cortex token is valid, however, the app has already authorized with different application credentials or same application but different version. The app needs to call again.

In this case, there is often a bug in your application.

hashtag
-32137 Cannot open output file

You are trying to a record but Cortex cannot open the output CSV or EDF file to write. Users should check the path or the permissions.

hashtag
-32138 Stream not supported for export

You are trying to a record but one of the data streams you requested is not available.

hashtag
-32139 Record is too short to export

When export to EDF file, the record length must be at least one second of data.

hashtag
-32140 Cannot unsubscribe a data stream

The app can get this error when calling unsubscribe a data stream. Please check if the stream has been subscribed.

hashtag
-32142 Unpublished application

This app is currently unpublished, so only the person who created it (the owner) can use it. To access unpublished app, they must log in to Emotiv Launcher with the same EmotivID used to create the Cortex App ID and Cortex Client ID.

If the owner of the app wants to share the app with other people, the owner needs to contact to publish the app.

hashtag
-32146 A record is being reported

We don't allow a record to be exported twice at the same time. You must wait for a record exporting to stop before calling on this record again.

hashtag
-32147 Record data is corrupted

Record data is corruped and cannot be exported.

hashtag
-32148 Timestamp of record is incorrect

There is something wrong with start and end time of the record and we cannot find the these timestamps in record data file. In this case, we cannot export the record.

hashtag
-32151 Cannot run Cortex on this machine

If Cortex cannot read hardware information of the machine, you will get this error when calling API.

hashtag
-32152 Headset is not ready yet

When a headset is requested to connect, it will take some time for Cortex to establish the connection and getting the first sample. If the app wants to do anything with headset e.g: createSession, subscribe, etc, before that, the app will get this error. In this case, the app needs to wait and retry later.

hashtag
-32153 Low disk space

The app will get this error when trying to when the free disk space on this machine is critical low. Users will need to create more disk space to continue.

hashtag
-32154 Invalid headset connection type

The app will get this error when trying to with an expected connection type but the headset is not available via that connection type.

hashtag
-32155 Opt-out feature is unavailable

The opt-out feature is not available with the current license. You can get this error when calling API. Please contact if you want to have the ability of record uploading opt-out.

hashtag
-32156 Cannot change Opt-out config

The opt-out feature is available with the current license. However, you cannot change the opt-out option. You can get this error when calling API. Please contact if you want to have the ability of changing opt-out option.

hashtag
-32157 Cannot change headset mapping

You cannot change the headset mapping of a connected headset.

hashtag
-32159 Cannot upgrading database

You will not likely get this error. However, if you get it, there must be something wrong with the database. Please contact .

hashtag
-32160 Record data is corrupted after post-processing

You cannot export the record because when running post-processing, record data is corrupted for some reason. Please contact for this case.

hashtag
-32161 Record is being post-processing

You cannot export the record because when record's post-processing is in progress. Please wait until it's done.

hashtag
-32173 The API is not supported for this application/platform/headset

You can get this error if the API is not supported in some cases.

For example, when the app is trying to run facial expression detection on a headset which doesn't support facial expression detection.

hashtag
-32175 Database is busy

You will get this error when the API call is trying to access to database but the database is busy with other operations. Please wait and try again.

hashtag
-32176 Cannot change headset config

You can get this error when calling API. Please make sure the headset connection is stable.

hashtag
-32178 Cannot update headband position

You can get this error when calling API but there is an active recording with this current headset.

hashtag
-32179 Local time error

You cannot work with headset if your local time is modified and different from actual time. If you got this error, please check the Date Time settings on your machine.

hashtag
-32182 Multi headset error

On some platforms like iOS, Android, Raspberry Pi, we support only 1 headset at a time. So if the app to the another headset while there is already connected headset, this error will be returned.

hashtag
-32183 The account has been suspended

If users attempt to login at least 5 times with incorrect user credentials, the account will be suspended for 15 minutes and the app will get this error.

hashtag
-32186 Record data already exists

When the app calls but record data already exists, no need to download, the app will get this error.

hashtag
-32188 Invalid authentication code

Only available for the Cortex embedded lib, related API: .

hashtag
-32189 Expired authentication code

Only available for the Cortex embedded lib, related API: .

hashtag
-32191 Cannot open database

This error can happen when there is some disk I/O error, e.g: users unplug the disk where Cortex's database is located.

hashtag
-32192 Cannot encrypt database

Cortex cannot generate encryption key to encrypt database. Please contact for this case.

hashtag
-32193 Unhandled database error

There are unhandled errors in database. Please contact for this case.

hashtag
-32198 Re-generating database key

Cortex is trying to re-generating database key. This can happen when we rotate database key. Please wait and try again.

hashtag
-32200 Cannot access records of other applications

Normally the app can only access the records that have been created by this app, unless it has the license key that record is created with. If the app doesn't have permission to access the record, it will get this error when calling these APIs: , , .

hashtag
-32206 Headset not supported

The headset is not supported for some feature. e.g: API.

hashtag
-32225 Forced logout

Cortex log the user out because some critical account availability for example: user has changed their password or user has deleted their account.

hashtag
-32226 Training profile incompatible with the headset

If the defined EEG channels in the training profile is not the same with the EEG channels of this headset, you will get this error. See API.

hashtag
-32227 Training profile incompatible with the EMOTIV Flex headset

If the training profile is loaded with EMOTIV Flex headset which doesn't have Epoc-based mapping, you will get this error. See API.

hashtag
-32228 Readonly training profile

The profile is ready and cannot be trained. Read more at .

hashtag
-32230 Unsupported headset in license

Emotiv licenses also limits the type of headset for specific data streams, especially 'eeg' or 'met' (see API). If you got this issue, please contact .

hashtag
-32232 License requires EEG

You will get this error if your app has enabled "Enable EEG for Professional devices" option when creating the app, however, you don't have any valid paid license.

This option should be enabled when you have Professional devices (EPOC, Flex) and want to access Premium data stream (EEG, high-resolution Performance Metrics). Please contact in this case.

Otherwise, please create another Cortex app with new client id and client secret, disable this option then run again.

Connecting to the Cortex API
EMOTIV customer supportarrow-up-right
EMOTIV customer supportarrow-up-right
authorize
EMOTIV customer supportarrow-up-right
Whitelisting Domains for EMOTIV Applications
createSession
close
createSession
updateSession
EMOTIV customer supportarrow-up-right
prerequisite
updateSession
subscribe
unsubscribe
createRecord
injectMarker
training
createRecord
authorize
authorize
authorize
generateNewToken
subscribe
unsubscribe
Data Subscription
getLicenseInfo
createRecord
createSession
updateSession
getLicenseInfo
authorize
authorize
updateHeadset
guidelines
getLicenseInfo
EMOTIV customer supportarrow-up-right
getLicenseInfo
authorize
authorize
getLicenseInfo
authorize
training profile
EMOTIV Launcherarrow-up-right
authorize
getUserLogin
training
here
load
setupProfile
training
getCurrentProfile
EMOTIV Launcherarrow-up-right
queryHeadsets
EMOTIV customer supportarrow-up-right
authorize
EMOTIV customer supportarrow-up-right
activate
querySessions
inject
stop
syncWithHeadsetClock
syncWithHeadsetClock
updateMarker
create
update
configMapping
configMapping
controlDevice
EMOTIV customer supportarrow-up-right
update
delete
create
exportRecord
stopRecord
exportRecord
load
authorize
authorize
export
export
EMOTIV customer supportarrow-up-right
exportRecord
authorize
connect a headset
connect a headset
configOptout
EMOTIV customer supportarrow-up-right
configOptout
EMOTIV customer supportarrow-up-right
EMOTIV customer supportarrow-up-right
EMOTIV customer supportarrow-up-right
updateHeadset
updateHeadsetCustomInfo
connects
requestToDownloadRecordData
loginWithAuthenticationCodearrow-up-right
loginWithAuthenticationCodearrow-up-right
EMOTIV customer supportarrow-up-right
EMOTIV customer supportarrow-up-right
queryRecords
exportRecord
getRecordInfos
updateHeadset
setupProfile
setupProfile
readonly profile
subscribe
EMOTIV customer supportarrow-up-right
EMOTIV customer supportarrow-up-right