{"title": "Getting Started with Submissions", "status": "open", "content": [{"file": "/docs/source/getting_started.rst", "status": "open", "options": {"filetype": "rst", "collapsible": false, "default_open": true, "convert_ext_links": true, "initial_header_level": 2}, "consortia": [{"uuid": "358aed10-9b9d-4e26-ab84-4bd162da182b", "@id": "/consortia/358aed10-9b9d-4e26-ab84-4bd162da182b/", "status": "open", "display_title": "SMaHT", "@type": ["Consortium", "Item"], "principals_allowed": {"view": ["system.Everyone"], "edit": ["group.admin"]}}], "identifier": "getting_started", "date_created": "2023-12-12T20:21:09.743548+00:00", "section_type": "Page Section", "submitted_by": {"error": "no view permissions"}, "last_modified": {"modified_by": {"error": "no view permissions"}, "date_modified": "2026-05-20T19:29:06.318280+00:00"}, "schema_version": "1", "submission_centers": [{"@id": "/submission-centers/9626d82e-8110-4213-ac75-0a50adf890ff/", "display_title": "HMS DAC", "@type": ["SubmissionCenter", "Item"], "status": "open", "uuid": "9626d82e-8110-4213-ac75-0a50adf890ff", "principals_allowed": {"view": ["system.Everyone"], "edit": ["group.admin"]}}], "@id": "/static-sections/442c8aa0-dc6c-43d7-814a-854af460b015/", "@type": ["StaticSection", "UserContent", "Item"], "uuid": "442c8aa0-dc6c-43d7-814a-854af460b015", "principals_allowed": {"view": ["system.Everyone"], "edit": ["group.admin"]}, "display_title": "getting_started", "content_as_html": "<div class=\"rst-container\"><h2>Getting Started</h2><p>In order to make your data accessible, searchable, and assessable, you should submit as much metadata as possible to the SMaHT system along with the raw files you have generated in your experiments.</p><p>These pages are designed to:</p><ul class=\"simple\"><li>Show you how to find out what kind of metadata we collect for your particular type of experiment.</li><li>Introduce the mechanisms by which you can submit your metadata and associated data files to SMaHT data portal.</li></ul><p>The primary way to submit data to SMaHT data portal is via Excel spreadsheet, as described below.</p><div class=\"admonition tip\"><p class=\"first admonition-title\">Tip</p><p>For more detailed and comprehensive documentation, please see our ReadTheDocs based documentation here:</p><ul class=\"simple\"><li><a class=\"reference external\" href=\"https://submitr.readthedocs.io/en/draft/\" target=\"_blank\" rel=\"noopener noreferrer\">https://submitr.readthedocs.io/en/draft/</a></li></ul><p>An overview of the actual metadata structure is pending, check back soon! Though for now a reference can be found here:</p><ul class=\"last simple\"><li><a class=\"reference external\" href=\"https://submitr.readthedocs.io/en/draft/object_model.html\" target=\"_blank\" rel=\"noopener noreferrer\">https://submitr.readthedocs.io/en/draft/object_model.html</a></li></ul></div><h3>Data Submission via Excel Spreadsheet</h3><p>Uploading metadata and associated data files to SMaHT data portal can be done using a software tool called <code>smaht-submitr</code>. This is a Python based command-line tool which is distributed on PyPi. The metadata is represented by an Excel spreadsheet (also called a <cite>workbook</cite>) which contains a number of sheets (also called <cite>worksheets</cite>).</p><p>Such Excel metadata workbooks:</p><ul class=\"simple\"><li>Are useful for submitting metadata and data for several sequencing experiments or samples.</li><li>Can be used to make bulk edits of submitted but not yet released metadata.</li><li>Contain multiple sheets where each sheet corresponds to an object type and each column a field of metadata.</li><li>Are used as input to the <code>smaht-submitr</code> software which validates submissions and pushes the content of the forms to our database.</li></ul><p>Spreadsheet generation tools may be made available in the future; please contact the DAC directly for data submission templates. More extensive documentation of the data submission process can be found <a class=\"reference external\" href=\"https://submitr.readthedocs.io/en/draft/\" target=\"_blank\" rel=\"noopener noreferrer\">here</a>.</p><h3>Installing the Submission Tool</h3><a class=\"reference external image-reference\" href=\"/static/img/docs/submitr_logo.png\"><img alt=\"Excel Spreadsheet Screenshot\" src=\"/static/img/docs/submitr_logo.png\"/></a><p>The SMaHT data portal submission tool is implemented as a command-line Python package, and is distributed on <a class=\"reference external\" href=\"https://pypi.org/project/smaht-submitr/\" target=\"_blank\" rel=\"noopener noreferrer\">PyPi</a>.  It requires Python version 3.9, 3.10, or 3.11.  Installation is done via the standard Python <code>pip</code> command-line install tool like this:</p><pre class=\"literal-block\">\npip install smaht-submitr\n</pre><div class=\"admonition tip\"><p class=\"first admonition-title\">Tip</p><p class=\"last\">If you do not have Python installed, please take a look at our documentation here as a guide: <a class=\"reference external\" href=\"https://submitr.readthedocs.io/en/draft/installation_prerequisites.html#installing-python\" target=\"_blank\" rel=\"noopener noreferrer\">Installing Python</a></p></div><div class=\"line-block\"><div class=\"line\"><br/></div></div><p>Once installed, these key commands will be available for execution from the command-line: <code>submit-metadata-bundle</code>, <code>resume-uploads</code></p><div class=\"admonition tip\"><p class=\"first admonition-title\">Tip</p><p class=\"last\">As of June 2024 we offer an alternative installation procedure to the primary procedure outlined below. This alternative does not require installing Python or anything; rather a self-contained binary is installed. This is supported only for MacOS and Linux. Please see the <a class=\"reference external\" href=\"https://submitr.readthedocs.io/en/latest/binary_installation.html\" target=\"_blank\" rel=\"noopener noreferrer\">Binary Installation</a> section for details. But in brief, to get the binary you would run: <cite>curl https://raw.githubusercontent.com/smaht-dac/submitr/master/install.sh | /bin/bash</cite></p></div><div class=\"line-block\"><div class=\"line\"><br/></div></div><h3>Templates</h3><p>A workbook containing worksheets for each item type with all properties available for submission can be found <a href=\"https://docs.google.com/spreadsheets/d/1LEaS5QTwm86iZjjKt3tKRe_P31sE9-aJZ7tMINxw3ZM/edit?usp=sharing\" target=\"_blank\" target=\"_blank\" rel=\"noopener noreferrer\">here</a>.</p><p>This workbook is a Google Sheet, and you can make a copy of it to your own Google Drive, or download it as an Excel file. For detailed information on an individual property, refer to its tooltip in the template by clicking or hovering over the column name.</p><p>An example of a filled out workbook ready for submission can be found <a href=\"https://docs.google.com/spreadsheets/d/1bnPIH6f3biLBL9R8mEgvBemLP3nbsyyCrJQuOstcm_I/edit?usp=sharing\" target=\"_blank\" target=\"_blank\" rel=\"noopener noreferrer\">here</a>.</p><div class=\"admonition tip\"><p class=\"first admonition-title\">Tip</p><p class=\"last\">The submission template is in flux. Please double check with DAC about getting the most up-to-date template before starting metadata submission! Changes to the template by version can be found <a class=\"reference external\" href=\"https://docs.google.com/document/d/1wDrr1hhk8JP9Eii5Qti7URV6vBy00a4Rse6WAIeiUWA/edit?usp=sharing\" target=\"_blank\" rel=\"noopener noreferrer\">here</a>.</p></div><div class=\"line-block\"><div class=\"line\"><br/></div></div><h3>Formatting Files for Submission</h3><p>Most commonly, the file format recommended for metadata submission to SMaHT Portal, is an Excel spreadsheet file (e.g. <code>your_metadata_file.xlsx</code>), comprised of one or more sheets. Note these important aspects of using the Excel spreadsheet format:</p><ol class=\"arabic simple\"><li>The spreadsheet must have a <strong>file suffix</strong> of <code>.xls</code> or <code>.xlsx</code>; there are no other requirements for the name of this file.</li><li>Each <strong>sheet name</strong> must be the <cite>exact</cite> name of a SMaHT Portal item or <cite>object</cite> defined within the system (e.g. <code>AlignedReads</code>).</li><li>Each sheet must have as its <strong>first row</strong> a special <cite>header</cite> row, which enumerates in each column, the <cite>exact</cite> names of the Portal object <strong>properties</strong> as the column names; order does <cite>not</cite> matter.</li><li>Each sheet may contain any number of <strong>data rows</strong> (<cite>directly</cite> below the header row), each representing an instance of the Portal object.</li><li>The values in the cells/columns of each data row correspond to <strong>property names</strong> in the same column of the header row.</li></ol><p>Note these important rules defining exactly the parts of the spreadsheet which are <strong>relevant</strong> for metadata submission.</p><ol class=\"arabic simple\"><li>The <strong>first row</strong> which is entirely <strong>empty</strong> marks the <strong>end of the data</strong>, and any subsequent rows will be entirely <strong>ignored</strong>; this means you can include comments in your spreadsheet in rows after (below) the first blank row indicating the end of data input.</li><li>The <strong>first column</strong> in the header row which is <strong>empty</strong> marks the <strong>end of the header</strong>, and any subsequent columns will be entirely <strong>ignored</strong>.</li><li>Sheets which are marked as <strong>hidden</strong> will be <strong>ignored</strong>; this provides a way of including sheets with other auxiliary information without their contents interfering with the submission tool.</li><li>Sheets which have a name enclosed in parenthesis, for example <code>(My Comments)</code>, will similarly be treated as <strong>hidden</strong> as described above.</li></ol><p>It's actually pretty intuitive, straightforward, and almost self-explanatory, as this example Excel screenshot should make clear:</p><a class=\"reference external image-reference\" href=\"/static/img/docs/excel_screenshot.png\"><img alt=\"Excel Spreadsheet Screenshot\" src=\"/static/img/docs/excel_screenshot.png\"/></a><div class=\"line-block\"><div class=\"line\"><br/></div></div><p>Notice that the first row comprises the property/column <cite>header</cite>, defining properties named <code>submitted_id</code>, <code>molecule</code>, <code>components</code>, and so on.</p><p>And also notice the multiple tabs at the bottom for the different sheets within the spreadsheet, representing (in this example) data for the Portal objects <code>CellCultureSample</code>, <code>Analyte</code>, <code>Library</code>, and so on.</p><div class=\"admonition tip\"><p class=\"first admonition-title\">Tip</p><p class=\"last\">Other file formats besides Excel actually <cite>are</cite> supported; see <a class=\"reference external\" href=\"https://submitr.readthedocs.io/en/draft/advanced_usage.html#other-files-formats\" target=\"_blank\" rel=\"noopener noreferrer\">this document</a> for more information.</p></div><div class=\"line-block\"><div class=\"line\"><br/></div></div><p>SMaHT object <cite>properties</cite> have different <cite>types</cite>. Many of the types are simply text (or <cite>strings</cite>). Other types are described below.</p><h4>Date/Time Properties</h4><p>For properties defined as <cite>date</cite> types, the required format is <code>YYYY-MM-DD</code>, for example <code>2024-02-09</code>.</p><p>For properties defined as <cite>date-time</cite> types, the required format is <code></code>, for example <code></code> (note the use of 24-hour based clock time). This will default to your local timezone; if you need to specify a timezone, use a suffix like <code>+hh:mm</code> where <code>hh</code> and <code>mm</code> are the hour and minute offsets from GMT (for example: <code>2024-02-09</code> <code>13:25:10+05:00</code>).</p><h4>Array Properties</h4><p>Some SMaHT data portal object properties are defined to be lists (or <cite>arrays</cite>) of values. To define the values for such array properties, separate the individual array values by a pipe character (<code>|</code>). For example, if an object defines an <code>alignment_details</code> property as an array type, use the value <code>Sorted|Phased</code> to set this value to an array with the two elements <code>Sorted</code> and <code>Phased</code>.</p><p>For more on this please see the more extensive documentation here: <a class=\"reference external\" href=\"https://submitr.readthedocs.io/en/draft/usage.html#array-properties\" target=\"_blank\" rel=\"noopener noreferrer\">Array Properties</a></p><p>Here is an example of date/time and array properties:</p><a class=\"reference external image-reference\" href=\"/static/img/docs/submitr_spreadsheet_date_time_and_array.png\"><img alt=\"Excel Spreadsheet Date-Time-Array Screenshot\" src=\"/static/img/docs/submitr_spreadsheet_date_time_and_array.png\"/></a><h4>Boolean Properties</h4><p>For properties defined as <cite>boolean</cite> types, meaning their value may be either <cite>true</cite> or <cite>false</cite>, simply use these values, i.e. <code>true</code> or <code>false</code>.</p><h4>Object Reference Properties</h4><p>Some Portal object properties references to other Portal objects (also known as <cite>linkTo</cite> properties). The values of these properties in the spreadsheet should be a uniquely identify the value for the object you are referencing. The identifying value property for an object varies depending on the specific object in question; the <code>uuid</code> property is common to all objects, but other common identifying properties are <code>submitted_id</code> and <code>accession</code>. These might be thought of (for the database savvy) as <cite>foreign</cite> keys. Here is a visual which should make this clear:</p><div class=\"line-block\"><div class=\"line\"><br/></div></div><a class=\"reference external image-reference\" href=\"/static/img/docs/submitr_spreadsheet_refutput.png\"><img alt=\"Spreadsheed Reference Screenshot\" src=\"/static/img/docs/submitr_spreadsheet_ref.png\"/></a><div class=\"line-block\"><div class=\"line\"><br/></div></div><p>It is important to know that the <code>smaht-submitr</code> tool and SMaHT data portal will ensure that the referenced objects actually exist within SMaHT data portal, <cite>or</cite> are defined within the spreadsheet itself; if this is not the case, an error will be returned.</p><div class=\"admonition tip\"><p class=\"first admonition-title\">Tip</p><p class=\"last\">Note that the <code>submitted_id</code> in the above example is in all CAPS. This property specifically requires any letters to be capitalized.</p></div><div class=\"line-block\"><div class=\"line\"><br/></div></div><p>You can view all of the supported SMaHT objects and their identifying (and required) properties, as well as reference data here:</p><ul class=\"simple\"><li><a class=\"reference external\" href=\"https://data.smaht.org/docs/user-guide/referencing-data\" target=\"_blank\" rel=\"noopener noreferrer\">https://data.smaht.org/docs/user-guide/referencing-data</a></li><li><a class=\"reference external\" href=\"https://submitr.readthedocs.io/en/draft/object_model.html\" target=\"_blank\" rel=\"noopener noreferrer\">https://submitr.readthedocs.io/en/draft/object_model.html</a></li></ul><h4>Implicit Properties</h4><p>Some SMaHT data portal objects require (or support) the <code>submission_centers</code> property. If you do not specify this though, <code>smaht-submitr</code> will <cite>automatically</cite> supply this particular property; it will be <cite>implicitly</cite> set to the submission center to which you belong.</p><h4>Nested Properties</h4><p>Though uncommon, some SMaHT data portal object properties defined to contain other <cite>nested</cite> objects, i.e. object which themselves are objects or are arrays of object. For more on this please see the more extensive documentation here: <a class=\"reference external\" href=\"https://submitr.readthedocs.io/en/draft/usage.html#nested-properties\" target=\"_blank\" rel=\"noopener noreferrer\">Nested Properties</a></p><h4>Property Deletions</h4><p>A column value within a (non-header) data row may be empty, but this only means that the value will be ignored when creating or updating the associated object. Though uncommon, the <cite>deletion</cite> of a property from an object is supported. Please see the more extensive documentation here: <a class=\"reference external\" href=\"https://submitr.readthedocs.io/en/draft/usage.html#property-deletions\" target=\"_blank\" rel=\"noopener noreferrer\">Property Deletions</a></p><h3>Validation</h3><p>Using the <code>--submit</code> option with the  <code>submit-metadata-bundle</code> command will perform validation of your metadata before submitting it (after prompting you to do so). But if you want to <cite>only</cite> run validation <cite>without</cite> submitting the metadata to SMaHT data portal, then invoke <code>submit-metadata-bundle</code> with the <code>--validate</code> option as follows:</p><pre class=\"literal-block\">\nsubmit-metadata-bundle your_metadata_file.xlsx --env &lt;environment-name&gt; --validate\n</pre><div class=\"admonition tip\"><p class=\"first admonition-title\">Tip</p><p class=\"last\">This feature basically constitutes a sort of \"<strong>dry run</strong>\" facility.</p></div><div class=\"line-block\"><div class=\"line\"><br/></div></div><p>To be more specific about the the validation checks, they include the following:</p><ol class=\"arabic simple\"><li>Ensures the basic integrity of the format of the metadata submission file.</li><li>Validates that objects defined within the metadata submission file conform to the corresponding SMaHT data portal schemas for these objects.</li><li>Confirms that any objects referenced within the submission file can be resolved, i.e. either they already exist within SMaHT data portal or are defined within the metadata submission file itself.</li><li>Verifies that referenced files (to be subsequently uploaded) actually exist on the file system.</li></ol><div class=\"line-block\"><div class=\"line\"><br/></div></div><p><strong>Note</strong>: If you try to resubmit your metadata sheet after fixing your validation errors, it is possible that you will get new, additional errors. Not all validation errors will be comprehensively reported at once. This is because there are two kinds (or phases) of validation: local client-side and remote server-side. You can learn more about the details of the validation process in the <a class=\"reference external\" href=\"https://submitr.readthedocs.io/en/draft/advanced_usage.html#more-on-validation\" target=\"_blank\" rel=\"noopener noreferrer\">Advanced Usage</a> section.</p><h3>Submission</h3><p>The type of submission supported is called \"metadata bundles\" or <cite>accessioning</cite>. The name of the command-line tool to initiate a submission is <code>submit-metadata-bundle</code>. A brief tour of this command, its arguments, and function is described below. To get additional information about the command, use the command:</p><pre class=\"literal-block\">\nsubmit-metadata-bundle --help\n</pre><p>To submit your metadata, run the following command:</p><pre class=\"literal-block\">\nsubmit-metadata-bundle your_metadata_file.xlsx --env data --submit\n</pre><p>where <code>&lt;your_metdata_file.xlsx&gt;</code> is the path to your metadata file. The argument passed to the <code>--env</code> option corresponds to the SMaHT environment name (e.g. <code>data</code>) from your keys file (as described in the <a class=\"reference external\" href=\"/docs/user-guide/credentials\">Credentials</a> section).</p><p>This will first validate your metadata, and if no errors were encountered, it will perform the actual metadata submission; you <cite>will</cite> be prompted for confirmation before the submission is started. If errors are encountered, the submission will <cite>not</cite> commence; you will <cite>not</cite> be able to submit until you fix the errors.</p><div class=\"admonition tip\"><p class=\"first admonition-title\">Tip</p><p class=\"last\">You can omit the <code>--env</code> option entirely if your keys file has only <cite>one</cite> single entry or if you have your <code>SMAHT_ENV</code> environment variable setup (see the <a class=\"reference external\" href=\"/docs/user-guide/credentials\">Credentials</a> section).</p></div><div class=\"line-block\"><div class=\"line\"><br/></div></div><p><strong>Note</strong>: If you opted to use a file other than <code>~/.smaht-keys.json</code> to store your credentials, you will need to use the <code>--keys</code> option with the path name to your alternate file as an argument or have your <code>SMAHT_KEYS</code> environment variable setup (see the <a class=\"reference external\" href=\"/docs/user-guide/credentials\">Credentials</a> section).</p><p>This command should do everything, <cite>including</cite> uploading any referenced files, which will be done after firstprompting the user for confirmation; see the <a class=\"reference external\" href=\"/docs/user-guide/uploading-files\">Uploading Files</a> section for more on this.</p><p>If you belong to multiple consortia and/or submission centers, you can also add the <code></code> and <code></code> options to explicitly specify which consortium or submission center you are submitting on behalf of; if you belong to only one, the command will automatically detect which groups you are a part of (based on your user profile) and use those.</p><div class=\"admonition tip\"><p class=\"first admonition-title\">Tip</p><p class=\"last\">You may wonder: Is it okay to submit the same metadata file more than once? The answer is: Yes. If any changes were made to the file, updates will be applied as expected.</p></div><h3>Getting Submission Info</h3><p>To view relevant information about a submission, use the command:</p><pre class=\"literal-block\">\ncheck-submission --env &lt;environment-name&gt; &lt;uuid&gt;\n</pre><p>where the <code>uuid</code> argument is the Submission tracking ID for the submission, which should have been displayed in the output of the <code>submit-metadata-bundle</code> command.</p><h3>Listing Recent Submissions</h3><p>To view a list of recent submissions (with submission UUID and submission date/time), in order of most to least recent, use the <code>list-submissions</code> command as follows:</p><pre class=\"literal-block\">\nlist-submissions --env &lt;environment-name&gt;\n</pre><p>Use the <code>--verbose</code> option to list more information for each of the recent submissions shown. You can control the maximum number of results output using the <code>--count</code> option with an integer count argument. Use the <code>--mine</code> option to see only your submissions.</p><h3>Example Screenshots</h3><p>The output of a successful <code>submit-metadata-bundle</code> <code>--submit</code> run will look something like this:</p><div class=\"line-block\"><div class=\"line\"><br/></div></div><a class=\"reference external image-reference\" href=\"/static/img/docs/submit_output.png\"><img alt=\"Submission Output Screenshot\" src=\"/static/img/docs/submit_output.png\"/></a><p>Notice the <strong>Submission tracking ID</strong> value as well as the <strong>Upload File ID</strong> values. These may be used in a subsequent <code>resume-uploads</code> invocation (see the Uploading Files section for more on this).</p><p>When instead specifying the <code>--validate</code> option, the output will look something like this:</p><div class=\"line-block\"><div class=\"line\"><br/></div></div><a class=\"reference external image-reference\" href=\"/static/img/docs/validate_output.png\"><img alt=\"Validation Output Screenshot\" src=\"/static/img/docs/validate_output.png\"/></a><p>If you additionally specify the <code>--verbose</code> option, the output will look something like this:</p><div class=\"line-block\"><div class=\"line\"><br/></div></div><a class=\"reference external image-reference\" href=\"/static/img/docs/validate_verbose_output.png\"><img alt=\"Validation Verbose Output Screenshot\" src=\"/static/img/docs/validate_verbose_output.png\"/></a></div>", "content": "===============\nGetting Started\n===============\n\nIn order to make your data accessible, searchable, and assessable, you should submit as much metadata as possible to the SMaHT system along with the raw files you have generated in your experiments.\n\nThese pages are designed to:\n\n* Show you how to find out what kind of metadata we collect for your particular type of experiment.\n* Introduce the mechanisms by which you can submit your metadata and associated data files to SMaHT data portal.\n\nThe primary way to submit data to SMaHT data portal is via Excel spreadsheet, as described below.\n\n.. TIP::\n   For more detailed and comprehensive documentation, please see our ReadTheDocs based documentation here:\n\n   * https://submitr.readthedocs.io/en/draft/\n\n   An overview of the actual metadata structure is pending, check back soon! Though for now a reference can be found here:\n\n   * https://submitr.readthedocs.io/en/draft/object_model.html\n\nData Submission via Excel Spreadsheet\n=====================================\n\nUploading metadata and associated data files to SMaHT data portal can be done using a software tool called ``smaht-submitr``. This is a Python based command-line tool which is distributed on PyPi. The metadata is represented by an Excel spreadsheet (also called a `workbook`) which contains a number of sheets (also called `worksheets`).\n\nSuch Excel metadata workbooks:\n\n* Are useful for submitting metadata and data for several sequencing experiments or samples.\n* Can be used to make bulk edits of submitted but not yet released metadata.\n* Contain multiple sheets where each sheet corresponds to an object type and each column a field of metadata.\n* Are used as input to the ``smaht-submitr`` software which validates submissions and pushes the content of the forms to our database.\n\nSpreadsheet generation tools may be made available in the future; please contact the DAC directly for data submission templates. More extensive documentation of the data submission process can be found `here <https://submitr.readthedocs.io/en/draft/>`_.\n\nInstalling the Submission Tool\n==============================\n\n.. image:: /static/img/docs/submitr_logo.png\n   :target: /static/img/docs/submitr_logo.png\n   :alt: Excel Spreadsheet Screenshot\n\nThe SMaHT data portal submission tool is implemented as a command-line Python package, and is distributed on `PyPi <https://pypi.org/project/smaht-submitr/>`_.  It requires Python version 3.9, 3.10, or 3.11.  Installation is done via the standard Python ``pip`` command-line install tool like this::\n\n    pip install smaht-submitr\n\n.. TIP::\n   If you do not have Python installed, please take a look at our documentation here as a guide: `Installing Python <https://submitr.readthedocs.io/en/draft/installation_prerequisites.html#installing-python>`_\n\n|\n\nOnce installed, these key commands will be available for execution from the command-line: ``submit-metadata-bundle``, ``resume-uploads``\n\n.. TIP::\n   As of June 2024 we offer an alternative installation procedure to the primary procedure outlined below. This alternative does not require installing Python or anything; rather a self-contained binary is installed. This is supported only for MacOS and Linux. Please see the `Binary Installation <https://submitr.readthedocs.io/en/latest/binary_installation.html>`_ section for details. But in brief, to get the binary you would run: `curl https://raw.githubusercontent.com/smaht-dac/submitr/master/install.sh | /bin/bash`\n\n\n|\n\nTemplates\n=========\n\nA workbook containing worksheets for each item type with all properties available for submission can be found |template_workbook|.\n\n.. |template_workbook| raw:: html\n\n   <a href=\"https://docs.google.com/spreadsheets/d/1LEaS5QTwm86iZjjKt3tKRe_P31sE9-aJZ7tMINxw3ZM/edit?usp=sharing\" target=\"_blank\">here</a>\n\nThis workbook is a Google Sheet, and you can make a copy of it to your own Google Drive, or download it as an Excel file. For detailed information on an individual property, refer to its tooltip in the template by clicking or hovering over the column name.\n\nAn example of a filled out workbook ready for submission can be found |example_workbook|.\n\n.. |example_workbook| raw:: html\n\n   <a href=\"https://docs.google.com/spreadsheets/d/1bnPIH6f3biLBL9R8mEgvBemLP3nbsyyCrJQuOstcm_I/edit?usp=sharing\" target=\"_blank\">here</a>\n\n.. TIP::\n   The submission template is in flux. Please double check with DAC about getting the most up-to-date template before starting metadata submission! Changes to the template by version can be found `here <https://docs.google.com/document/d/1wDrr1hhk8JP9Eii5Qti7URV6vBy00a4Rse6WAIeiUWA/edit?usp=sharing>`__.\n\n|\n\nFormatting Files for Submission\n===============================\nMost commonly, the file format recommended for metadata submission to SMaHT Portal, is an Excel spreadsheet file (e.g. ``your_metadata_file.xlsx``), comprised of one or more sheets. Note these important aspects of using the Excel spreadsheet format:\n\n#. The spreadsheet must have a **file suffix** of ``.xls`` or ``.xlsx``; there are no other requirements for the name of this file.\n#. Each **sheet name** must be the `exact` name of a SMaHT Portal item or `object` defined within the system (e.g. ``AlignedReads``).\n#. Each sheet must have as its **first row** a special `header` row, which enumerates in each column, the `exact` names of the Portal object **properties** as the column names; order does `not` matter.\n#. Each sheet may contain any number of **data rows** (`directly` below the header row), each representing an instance of the Portal object.\n#. The values in the cells/columns of each data row correspond to **property names** in the same column of the header row.\n\nNote these important rules defining exactly the parts of the spreadsheet which are **relevant** for metadata submission.\n\n#. The **first row** which is entirely **empty** marks the **end of the data**, and any subsequent rows will be entirely **ignored**; this means you can include comments in your spreadsheet in rows after (below) the first blank row indicating the end of data input.\n#. The **first column** in the header row which is **empty** marks the **end of the header**, and any subsequent columns will be entirely **ignored**.\n#. Sheets which are marked as **hidden** will be **ignored**; this provides a way of including sheets with other auxiliary information without their contents interfering with the submission tool.\n#. Sheets which have a name enclosed in parenthesis, for example ``(My Comments)``, will similarly be treated as **hidden** as described above.\n\nIt's actually pretty intuitive, straightforward, and almost self-explanatory, as this example Excel screenshot should make clear:\n\n.. image:: /static/img/docs/excel_screenshot.png\n   :target: /static/img/docs/excel_screenshot.png\n   :alt: Excel Spreadsheet Screenshot\n\n|\n\nNotice that the first row comprises the property/column `header`, defining properties named ``submitted_id``, ``molecule``, ``components``, and so on.\n\nAnd also notice the multiple tabs at the bottom for the different sheets within the spreadsheet, representing (in this example) data for the Portal objects ``CellCultureSample``, ``Analyte``, ``Library``, and so on.\n\n.. TIP::\n   Other file formats besides Excel actually `are` supported; see `this document <https://submitr.readthedocs.io/en/draft/advanced_usage.html#other-files-formats>`_ for more information.\n\n|\n\nSMaHT object `properties` have different `types`. Many of the types are simply text (or `strings`). Other types are described below.\n\nDate/Time Properties\n~~~~~~~~~~~~~~~~~~~~\n\nFor properties defined as `date` types, the required format is ``YYYY-MM-DD``, for example ``2024-02-09``.\n\nFor properties defined as `date-time` types, the required format is ``YYYY-MM-DD hh:mm:ss``, for example ``2024-02-09 13:25:10`` (note the use of 24-hour based clock time). This will default to your local timezone; if you need to specify a timezone, use a suffix like ``+hh:mm`` where ``hh`` and ``mm`` are the hour and minute offsets from GMT (for example: ``2024-02-09`` ``13:25:10+05:00``).\n\nArray Properties\n~~~~~~~~~~~~~~~~\n\nSome SMaHT data portal object properties are defined to be lists (or `arrays`) of values. To define the values for such array properties, separate the individual array values by a pipe character (``|``). For example, if an object defines an ``alignment_details`` property as an array type, use the value ``Sorted|Phased`` to set this value to an array with the two elements ``Sorted`` and ``Phased``.\n\nFor more on this please see the more extensive documentation here: `Array Properties <https://submitr.readthedocs.io/en/draft/usage.html#array-properties>`_\n\nHere is an example of date/time and array properties:\n\n.. image:: /static/img/docs/submitr_spreadsheet_date_time_and_array.png\n   :target: /static/img/docs/submitr_spreadsheet_date_time_and_array.png\n   :alt: Excel Spreadsheet Date-Time-Array Screenshot\n\nBoolean Properties\n~~~~~~~~~~~~~~~~~~\n\nFor properties defined as `boolean` types, meaning their value may be either `true` or `false`, simply use these values, i.e. ``true`` or ``false``.\n\nObject Reference Properties\n~~~~~~~~~~~~~~~~~~~~~~~~~~~\n\nSome Portal object properties references to other Portal objects (also known as `linkTo` properties). The values of these properties in the spreadsheet should be a uniquely identify the value for the object you are referencing. The identifying value property for an object varies depending on the specific object in question; the ``uuid`` property is common to all objects, but other common identifying properties are ``submitted_id`` and ``accession``. These might be thought of (for the database savvy) as `foreign` keys. Here is a visual which should make this clear:\n\n|\n\n.. image:: /static/img/docs/submitr_spreadsheet_ref.png\n    :target: /static/img/docs/submitr_spreadsheet_refutput.png\n    :alt: Spreadsheed Reference Screenshot\n\n|\n\nIt is important to know that the ``smaht-submitr`` tool and SMaHT data portal will ensure that the referenced objects actually exist within SMaHT data portal, `or` are defined within the spreadsheet itself; if this is not the case, an error will be returned.\n\n.. TIP::\n   Note that the ``submitted_id`` in the above example is in all CAPS. This property specifically requires any letters to be capitalized.\n\n|\n\nYou can view all of the supported SMaHT objects and their identifying (and required) properties, as well as reference data here:\n\n* https://data.smaht.org/docs/user-guide/referencing-data\n* https://submitr.readthedocs.io/en/draft/object_model.html\n\nImplicit Properties\n~~~~~~~~~~~~~~~~~~~\n\nSome SMaHT data portal objects require (or support) the ``submission_centers`` property. If you do not specify this though, ``smaht-submitr`` will `automatically` supply this particular property; it will be `implicitly` set to the submission center to which you belong.\n\nNested Properties\n~~~~~~~~~~~~~~~~~\n\nThough uncommon, some SMaHT data portal object properties defined to contain other `nested` objects, i.e. object which themselves are objects or are arrays of object. For more on this please see the more extensive documentation here: `Nested Properties <https://submitr.readthedocs.io/en/draft/usage.html#nested-properties>`_\n\nProperty Deletions\n~~~~~~~~~~~~~~~~~~\n\nA column value within a (non-header) data row may be empty, but this only means that the value will be ignored when creating or updating the associated object. Though uncommon, the `deletion` of a property from an object is supported. Please see the more extensive documentation here: `Property Deletions <https://submitr.readthedocs.io/en/draft/usage.html#property-deletions>`_\n\nValidation\n==========\n\nUsing the ``--submit`` option with the  ``submit-metadata-bundle`` command will perform validation of your metadata before submitting it (after prompting you to do so). But if you want to `only` run validation `without` submitting the metadata to SMaHT data portal, then invoke ``submit-metadata-bundle`` with the ``--validate`` option as follows::\n\n   submit-metadata-bundle your_metadata_file.xlsx --env <environment-name> --validate\n\n.. TIP::\n   This feature basically constitutes a sort of \"**dry run**\" facility.\n\n|\n\nTo be more specific about the the validation checks, they include the following:\n\n#. Ensures the basic integrity of the format of the metadata submission file.\n#. Validates that objects defined within the metadata submission file conform to the corresponding SMaHT data portal schemas for these objects.\n#. Confirms that any objects referenced within the submission file can be resolved, i.e. either they already exist within SMaHT data portal or are defined within the metadata submission file itself.\n#. Verifies that referenced files (to be subsequently uploaded) actually exist on the file system.\n\n|\n\n**Note**: If you try to resubmit your metadata sheet after fixing your validation errors, it is possible that you will get new, additional errors. Not all validation errors will be comprehensively reported at once. This is because there are two kinds (or phases) of validation: local client-side and remote server-side. You can learn more about the details of the validation process in the `Advanced Usage <https://submitr.readthedocs.io/en/draft/advanced_usage.html#more-on-validation>`_ section.\n\nSubmission\n==========\n\nThe type of submission supported is called \"metadata bundles\" or `accessioning`. The name of the command-line tool to initiate a submission is ``submit-metadata-bundle``. A brief tour of this command, its arguments, and function is described below. To get additional information about the command, use the command::\n\n  submit-metadata-bundle --help\n\nTo submit your metadata, run the following command::\n\n   submit-metadata-bundle your_metadata_file.xlsx --env data --submit\n\nwhere ``<your_metdata_file.xlsx>`` is the path to your metadata file. The argument passed to the ``--env`` option corresponds to the SMaHT environment name (e.g. ``data``) from your keys file (as described in the `Credentials </docs/user-guide/credentials>`_ section).\n\nThis will first validate your metadata, and if no errors were encountered, it will perform the actual metadata submission; you `will` be prompted for confirmation before the submission is started. If errors are encountered, the submission will `not` commence; you will `not` be able to submit until you fix the errors.\n\n.. TIP::\n   You can omit the ``--env`` option entirely if your keys file has only `one` single entry or if you have your ``SMAHT_ENV`` environment variable setup (see the `Credentials </docs/user-guide/credentials>`_ section).\n\n|\n\n**Note**: If you opted to use a file other than ``~/.smaht-keys.json`` to store your credentials, you will need to use the ``--keys`` option with the path name to your alternate file as an argument or have your ``SMAHT_KEYS`` environment variable setup (see the `Credentials </docs/user-guide/credentials>`_ section).\n\nThis command should do everything, `including` uploading any referenced files, which will be done after first\nprompting the user for confirmation; see the `Uploading Files </docs/user-guide/uploading-files>`_ section for more on this.\n\nIf you belong to multiple consortia and/or submission centers, you can also add the ``--consortium <consortium>`` and ``--submission-center <submission-center>`` options to explicitly specify which consortium or submission center you are submitting on behalf of; if you belong to only one, the command will automatically detect which groups you are a part of (based on your user profile) and use those.\n\n.. TIP::\n   You may wonder: Is it okay to submit the same metadata file more than once? The answer is: Yes. If any changes were made to the file, updates will be applied as expected.\n\nGetting Submission Info\n=======================\nTo view relevant information about a submission, use the command::\n\n   check-submission --env <environment-name> <uuid>\n\nwhere the ``uuid`` argument is the Submission tracking ID for the submission, which should have been displayed in the output of the ``submit-metadata-bundle`` command.\n\nListing Recent Submissions\n==========================\nTo view a list of recent submissions (with submission UUID and submission date/time), in order of most to least recent, use the ``list-submissions`` command as follows::\n\n   list-submissions --env <environment-name>\n\nUse the ``--verbose`` option to list more information for each of the recent submissions shown. You can control the maximum number of results output using the ``--count`` option with an integer count argument. Use the ``--mine`` option to see only your submissions.\n\nExample Screenshots\n===================\n\nThe output of a successful ``submit-metadata-bundle`` ``--submit`` run will look something like this:\n\n|\n\n.. image:: /static/img/docs/submit_output.png\n    :target: /static/img/docs/submit_output.png\n    :alt: Submission Output Screenshot\n\nNotice the **Submission tracking ID** value as well as the **Upload File ID** values. These may be used in a subsequent ``resume-uploads`` invocation (see the Uploading Files section for more on this).\n\nWhen instead specifying the ``--validate`` option, the output will look something like this:\n\n|\n\n.. image:: /static/img/docs/validate_output.png\n    :target: /static/img/docs/validate_output.png\n    :alt: Validation Output Screenshot\n\nIf you additionally specify the ``--verbose`` option, the output will look something like this:\n\n|\n\n.. image:: /static/img/docs/validate_verbose_output.png\n    :target: /static/img/docs/validate_verbose_output.png\n    :alt: Validation Verbose Output Screenshot", "filetype": "rst"}], "consortia": [{"@type": ["Consortium", "Item"], "uuid": "358aed10-9b9d-4e26-ab84-4bd162da182b", "@id": "/consortia/358aed10-9b9d-4e26-ab84-4bd162da182b/", "status": "open", "display_title": "SMaHT", "principals_allowed": {"view": ["system.Everyone"], "edit": ["group.admin"]}}], "identifier": "docs/submission/getting-started-with-submissions", "date_created": "2024-05-29T01:43:13.674722+00:00", "last_modified": {"modified_by": {"error": "no view permissions"}, "date_modified": "2026-05-20T19:29:50.717282+00:00"}, "schema_version": "1", "table-of-contents": {"enabled": true, "skip-depth": 1, "header-depth": 4, "include-top-link": false}, "submission_centers": [{"status": "open", "@type": ["SubmissionCenter", "Item"], "uuid": "9626d82e-8110-4213-ac75-0a50adf890ff", "@id": "/submission-centers/9626d82e-8110-4213-ac75-0a50adf890ff/", "display_title": "HMS DAC", "principals_allowed": {"view": ["system.Everyone"], "edit": ["group.admin"]}}], "@id": "/docs/submission/getting-started-with-submissions", "@type": ["DocsSubmissionGetting-started-with-submissionsPage", "DocsSubmissionPage", "DocsPage", "StaticPage", "Portal"], "uuid": "dad6eb69-bdd0-4409-898a-6e95ba420bc0", "principals_allowed": {"view": ["system.Everyone"], "edit": ["group.admin"]}, "display_title": "Getting Started with Submissions", "@context": "/docs/submission/getting-started-with-submissions", "is_leaf": true, "toc": {"enabled": true, "skip-depth": 1, "header-depth": 4, "include-top-link": false}, "next": {"identifier": "docs/submission/links-to-existing-data", "title": "Linking Metadata During Submission", "status": "open", "content": [{"status": "open", "@id": "/static-sections/6206008f-9288-4156-b55d-52a75f5332e8/", "uuid": "6206008f-9288-4156-b55d-52a75f5332e8", "@type": ["StaticSection", "UserContent", "Item"], "display_title": "referencing_data", "principals_allowed": {"view": ["system.Everyone"], "edit": ["group.admin"]}}], "consortia": [{"display_title": "SMaHT", "uuid": "358aed10-9b9d-4e26-ab84-4bd162da182b", "status": "open", "@id": "/consortia/358aed10-9b9d-4e26-ab84-4bd162da182b/", "@type": ["Consortium", "Item"], "principals_allowed": {"view": ["system.Everyone"], "edit": ["group.admin"]}}], "date_created": "2024-05-29T01:43:13.801792+00:00", "last_modified": {"modified_by": {"error": "no view permissions"}, "date_modified": "2026-05-20T19:29:50.850829+00:00"}, "schema_version": "1", "table-of-contents": {"enabled": true, "skip-depth": 1, "header-depth": 4, "include-top-link": false}, "submission_centers": [{"uuid": "9626d82e-8110-4213-ac75-0a50adf890ff", "status": "open", "@type": ["SubmissionCenter", "Item"], "display_title": "HMS DAC", "@id": "/submission-centers/9626d82e-8110-4213-ac75-0a50adf890ff/", "principals_allowed": {"view": ["system.Everyone"], "edit": ["group.admin"]}}], "@id": "/docs/submission/links-to-existing-data", "@type": ["DocsSubmissionLinks-to-existing-dataPage", "DocsSubmissionPage", "DocsPage", "StaticPage", "Portal"], "uuid": "1a2da742-acc2-44e2-b5d9-249fe3e837e1", "principals_allowed": {"view": ["system.Everyone"], "edit": ["group.admin"]}, "display_title": "Linking Metadata During Submission", "is_leaf": true, "sibling_length": 3, "sibling_position": 1}, "parent": {"identifier": "docs/submission", "parent": {"identifier": "docs", "parent": {"identifier": "", "@id": "/", "display_title": "Home", "@type": ["DirectoryPage", "StaticPage", "Portal"]}, "@id": "/docs", "uuid": "089319c4-3ce9-4ec1-bd0b-5451a48bd99e", "display_title": "Documentation", "@type": ["DocsPage", "DirectoryPage", "StaticPage", "Portal"], "sibling_length": 5, "sibling_position": 3}, "title": "Submission", "status": "open", "consortia": [{"display_title": "SMaHT", "uuid": "358aed10-9b9d-4e26-ab84-4bd162da182b", "@id": "/consortia/358aed10-9b9d-4e26-ab84-4bd162da182b/", "status": "open", "@type": ["Consortium", "Item"], "principals_allowed": {"view": ["system.Everyone"], "edit": ["group.admin"]}}], "date_created": "2024-05-29T01:43:13.395136+00:00", "last_modified": {"modified_by": {"error": "no view permissions"}, "date_modified": "2026-05-20T19:29:50.474187+00:00"}, "schema_version": "1", "table-of-contents": {"enabled": true, "skip-depth": 1, "header-depth": 4, "include-top-link": false}, "submission_centers": [{"@id": "/submission-centers/9626d82e-8110-4213-ac75-0a50adf890ff/", "display_title": "HMS DAC", "status": "open", "uuid": "9626d82e-8110-4213-ac75-0a50adf890ff", "@type": ["SubmissionCenter", "Item"], "principals_allowed": {"view": ["system.Everyone"], "edit": ["group.admin"]}}], "@id": "/docs/submission", "@type": ["DocsSubmissionPage", "DocsPage", "DirectoryPage", "StaticPage", "Portal"], "uuid": "6523af8e-34e5-40eb-9e09-710a41b824a4", "principals_allowed": {"view": ["system.Everyone"], "edit": ["group.admin"]}, "display_title": "Submission", "sibling_length": 3, "sibling_position": 1}, "sibling_length": 3, "sibling_position": 0}