MCPcopy Create free account

hub / github.com/internetarchive/openlibrary / functions

Functions6,179 in github.com/internetarchive/openlibrary

↓ 1 callersFunctionconstructDataObject
* Creates an object that represents an update to a patron's observations. * * Data object is expected by the server to have the following form: * {
openlibrary/components/ObservationForm/ObservationService.js:50
↓ 1 callersMethodcontributors
(data)
scripts/partner_batch_imports.py:280
↓ 1 callersMethodcontributors
Return a list of author-dicts or None.
scripts/providers/isbndb.py:116
↓ 1 callersMethodconvertToDisplayType
* Given a technical tag type, returns a type string that can be * displayed in the UI. * * @param {String} tagType The technical tag ty
openlibrary/plugins/openlibrary/js/bulk-tagger/models/Tag.js:126
↓ 1 callersMethodconvertToType
* Returns the technical tag type corresponding to the given * UI-ready type string. * * @param {String} displayType A UI-ready type str
openlibrary/plugins/openlibrary/js/bulk-tagger/models/Tag.js:110
↓ 1 callersFunctionconvert_dict
>>> convert_dict({'author': {'key': '/authors/OL1A'}}, {'/authors/': '/a/'}) {'author': {'key': '/a/OL1A'}}
openlibrary/plugins/upstream/adapter.py:42
↓ 1 callersFunctionconvert_observation_ids
Given a dictionary of type and value IDs, returns a dictionary of equivalent type and value strings. return: Dictionary of type and value
openlibrary/core/observations.py:582
↓ 1 callersFunctionconvert_pressbooks_to_ol
(data)
scripts/import_pressbooks.py:37
↓ 1 callersFunctioncopy_list
(src, dest, list_key, comment)
scripts/copydocs.py:276
↓ 1 callersFunctioncopy_preferences_to_store
(keys, verbose: bool = False)
scripts/migrations/write_prefs_to_store.py:25
↓ 1 callersMethodcopy_with
(self, thing: Thing | SeedSubjectString)
openlibrary/core/lists/model.py:479
↓ 1 callersMethodcount_distinct_observations
Fetches the number of works in which the given user has made at least one observation. return: The number of works for which
openlibrary/core/observations.py:858
↓ 1 callersMethodcount_files_in_zip
(filepath)
openlibrary/coverstore/archive.py:418
↓ 1 callersMethodcount_observations
For a given work, fetches the count of each observation made for the work. Counts are returned in a list, grouped by observation typ
openlibrary/core/observations.py:823
↓ 1 callersMethodcount_unique_respondents_by_type
Returns the total number of respondents who have made an observation per each type of a work ID. return: Dictionary of total
openlibrary/core/observations.py:790
↓ 1 callersMethodcount_user_books_on_shelf
( cls, username: str, bookshelf_id: int, )
openlibrary/core/bookshelves.py:186
↓ 1 callersMethodcount_works_with_notes_by_user
Counts the total number of works logged by this 'username'
openlibrary/core/booknotes.py:79
↓ 1 callersMethodcreate
Args: username (unicode) - the username (slug) of the account. Usernames must be unique
openlibrary/accounts/model.py:502
↓ 1 callersMethodcreateBulkTagger
* Creates a new Bulk Tagger component and attaches it to the DOM. * * Sets the value of `IntegratedLibrarianEnvironment.bulkTagger`
openlibrary/plugins/openlibrary/js/ile/index.js:80
↓ 1 callersMethodcreateDropdownListAffordance
* Creates and hydrates a new "Add to list" dropdown affordance. * * @param {string} listKey Unique identifier for a list * @param {stri
openlibrary/plugins/openlibrary/js/my-books/MyBooksDropper/ReadingLists.js:336
↓ 1 callersFunctioncreateEditor
({ element, content, placeholder, onUpdate, onTransaction, enableCode = false })
openlibrary/components/lit/editor-core.js:24
↓ 1 callersFunctioncreateList
(userKey, data)
openlibrary/plugins/openlibrary/js/lists/ListService.js:15
↓ 1 callersMethodcreateMenuOption
* Creates a new menu option affordance based on the current menu option state. * * Stores newly created element as `rootElement`. The new e
openlibrary/plugins/openlibrary/js/bulk-tagger/BulkTagger/MenuOption.js:93
↓ 1 callersMethodcreateModalContentFromTemplate
* Creates a new element containing the check-in form and `colorbox` modal content. * * @returns {HTMLElement}
openlibrary/plugins/openlibrary/js/my-books/MyBooksDropper/CheckInComponents.js:181
↓ 1 callersMethodcreateNewList
* Creates a new patron list. * * When a new list is created, the list's title and description * are taken from the form. The patron's u
openlibrary/plugins/openlibrary/js/my-books/CreateListForm.js:82
↓ 1 callersFunctioncreateProviderRow
(index)
openlibrary/plugins/openlibrary/js/add_provider.js:13
↓ 1 callersFunctioncreateRequest
(olids, action, type, comment = null, primary = null)
openlibrary/plugins/openlibrary/js/merge-request-table/MergeRequestService.js:7
↓ 1 callersMethodcreateSearchMenuOption
* Creates, hydrates, and returns a new menu option based on a search result. * * In addition to the usual click listener, the newly created
openlibrary/plugins/openlibrary/js/bulk-tagger/BulkTagger.js:460
↓ 1 callersFunctioncreateSelectOptions
(values)
openlibrary/plugins/openlibrary/js/add_provider.js:54
↓ 1 callersFunctioncreateTemplate
(selector)
openlibrary/plugins/openlibrary/js/jquery.repeat.js:25
↓ 1 callersFunctioncreateTestEditor
(markdownContent, { enableCode = false } = {})
tests/unit/js/OLMarkdownEditor.test.js:22
↓ 1 callersMethodcreate_account_manager
(self)
openlibrary/mocks/mock_infobase.py:47
↓ 1 callersFunctioncreate_batch
Creates Standard Ebook batch import job. Attempts to find existing Standard Ebooks import batch. If nothing is found, a new batch is created.
scripts/import_standard_ebooks.py:61
↓ 1 callersFunctioncreate_context_for_script
These are the defaults we will use when executing from scripts. Why not set these as default all the time? Because we still run many thin
openlibrary/utils/request_context.py:240
↓ 1 callersFunctioncreate_edition_from_amazon_metadata
Fetches Amazon metadata by id from Amazon Product Advertising API, attempts to create OL edition from metadata, and returns the resulting edition
openlibrary/core/vendors.py:750
↓ 1 callersFunctioncreate_import_jobs
Creates Open Textbooks batch import job. Attempts to find existing Open Textbooks import batch. If nothing is found, a new batch is created.
scripts/import_open_textbook_library.py:106
↓ 1 callersMethodcreate_loan
(self, identifier, userid, format, ol_key)
openlibrary/core/lending.py:987
↓ 1 callersFunctioncreate_ol_subjects_for_ocaid
(ocaid, subjects)
openlibrary/catalog/add_book/__init__.py:375
↓ 1 callersMethodcreate_request
( username, action="", mr_type=None, olids="", comment: str | None = N
openlibrary/plugins/upstream/edits.py:147
↓ 1 callersMethodcreate_series_from_form_data
Create any __new__ series in the provided array. Updates the series dicts _in place_ with the new key. :param list[dict] seri
openlibrary/plugins/upstream/addbook.py:162
↓ 1 callersFunctioncreate_session_with_retries
Creates a requests Session configured with automatic retries.
scripts/update_stale_ocaid_references.py:30
↓ 1 callersFunctioncreate_session_with_retries
Creates a requests Session configured with automatic retries.
scripts/bulk_load_ia_query.py:124
↓ 1 callersFunctioncreate_stats_client
Create the client which can be used for logging statistics
openlibrary/core/stats.py:22
↓ 1 callersFunctioncreate_tag
(tag: dict)
openlibrary/plugins/upstream/addtag.py:64
↓ 1 callersMethodcreate_title
(mr_type: int, olids: list[str])
openlibrary/plugins/upstream/edits.py:247
↓ 1 callersMethodcreate_url
(mr_type: int, olids: list[str], primary: str | None = None)
openlibrary/plugins/upstream/edits.py:238
↓ 1 callersFunctioncreate_verification_cookie_value
Create a signed verification cookie value. Returns: str: Cookie value in format "vf/session_id,signature"
openlibrary/accounts/model.py:125
↓ 1 callersMethodcreation_time
(self)
openlibrary/accounts/model.py:297
↓ 1 callersFunctioncron_trigger_to_crontab
Returns a standard crontab string representation of this trigger. Only the fields minute, hour, day, month, and day_of_week are included, as
scripts/utils/scheduler.py:125
↓ 1 callersFunctioncsv_to_ol_json_item
converts a line to a book item
scripts/partner_batch_imports.py:334
↓ 1 callersFunctioncurrent_year
()
openlibrary/utils/dateutil.py:108
↓ 1 callersFunctiondatetime_from_isoformat
Returns datetime object, or None
openlibrary/plugins/upstream/borrow.py:328
↓ 1 callersFunctiondatetimestr_to_int
Convert an OL datetime to a timestamp integer. :param str or dict datestr: Either a string like `"2017-09-02T21:26:46.300245"` or a dict lik
openlibrary/solr/updater/work.py:243
↓ 1 callersFunctiondays_in_current_month
()
openlibrary/utils/dateutil.py:19
↓ 1 callersFunctiondays_since
(then: datetime, now: datetime | None = None)
openlibrary/core/helpers.py:123
↓ 1 callersMethoddb_fetch
(self, key: str)
openlibrary/plugins/worksearch/autocomplete.py:35
↓ 1 callersFunctionddc_transform
(sf: luqum.tree.SearchField)
openlibrary/plugins/worksearch/schemes/works.py:707
↓ 1 callersMethoddecode_field
(self, field: etree._Element)
openlibrary/catalog/marc/marc_xml.py:97
↓ 1 callersFunctiondecrypt_s3_keys
Decrypt a Fernet token back to (access, secret). Raises on invalid/tampered input.
openlibrary/accounts/model.py:101
↓ 1 callersMethoddedupe_items
(self, items: list[dict])
openlibrary/core/imports.py:61
↓ 1 callersFunctiondelete
(path)
scripts/pull-templates.py:53
↓ 1 callersMethoddeleteCheckIn
* Posts request to delete the read date record with the given ID. * * @param {string} eventId * @returns {Promise<Response>}
openlibrary/plugins/openlibrary/js/my-books/MyBooksDropper/CheckInComponents.js:252
↓ 1 callersMethoddelete_by_username_and_work
(cls, username, work_id)
openlibrary/core/bookshelves_events.py:221
↓ 1 callersMethoddelete_by_username_and_year
(cls, username: str, year: int)
openlibrary/core/yearly_reading_goals.py:110
↓ 1 callersMethoddelete_files
(self)
openlibrary/coverstore/archive.py:328
↓ 1 callersFunctiondelete_loan
(loan_key, loan=None)
openlibrary/plugins/upstream/borrow.py:470
↓ 1 callersFunctiondelete_old_links
()
scripts/expire_accounts.py:8
↓ 1 callersFunctiondelete_records
Deletes batches of `merge-authors-debug` records. A batch will contain no more than 100 records. If `batches` is negative, it will dele
scripts/migrations/delete_merge_debug.py:25
↓ 1 callersFunctiondisableButton
* Switches the given button to a disabled state. * * @param {HTMLElement} buttonElement
openlibrary/plugins/openlibrary/js/patron_exports.js:6
↓ 1 callersFunctiondisassociate_dark_ocaids
(s3_keys, es_editions, test=True)
scripts/update_stale_ocaid_references.py:101
↓ 1 callersMethoddismiss
* Dismiss the banner: fire ol-banner-dismiss, run the exit transition, * and remove the element from the DOM. Persistence is the host app's
openlibrary/components/lit/OlBanner.js:142
↓ 1 callersFunctiondispatchSubmitOnForm
* Dispatches a submit-check-in event on the form element * and waits for async resolution. * @param {CheckInComponents} components * @param {{year:
tests/unit/js/my-books.test.js:50
↓ 1 callersFunctiondisplayModal
* Displays a model identified by the given identifier. * * Optionally fires a reload event to a list with the given ID. * * @param {HTMLElement} c
openlibrary/plugins/openlibrary/js/modals/index.js:378
↓ 1 callersFunctiondo_flip
Given an author import dict, flip its name and any alternate_names in place i.e. Smith, John => John Smith
openlibrary/catalog/add_book/load_book.py:116
↓ 1 callersMethoddo_merge
Performs the merge and returns the list of docs to save. :param str master: key of master doc :param list of str duplicates:
openlibrary/plugins/upstream/merge_authors.py:81
↓ 1 callersMethoddoc_filter
Exclude certain documents
openlibrary/plugins/worksearch/autocomplete.py:46
↓ 1 callersMethoddoc_wrap
Modify the returned solr document in place.
openlibrary/plugins/worksearch/autocomplete.py:41
↓ 1 callersFunctiondoes_seed_have_metadata
Returns True if the seed has any metadata.
openlibrary/core/models.py:488
↓ 1 callersMethoddummy_edit
(self, key)
openlibrary/plugins/openlibrary/connection.py:250
↓ 1 callersMethoddummy_recentchange
(self, key)
openlibrary/plugins/openlibrary/connection.py:267
↓ 1 callersFunctiondump_yaml
(data)
openlibrary/core/formats.py:17
↓ 1 callersFunctionencode
(key, value, out)
openlibrary/coverstore/utils.py:185
↓ 1 callersFunctionencode_url_path
Encodes the path part of the url to avoid issues with non-latin characters as non-latin characters was breaking `web.seeother`. >>> encode_ur
openlibrary/plugins/upstream/addbook.py:180
↓ 1 callersFunctionencrypt_s3_keys
Encrypt S3 access:secret into a Fernet token for cookie storage.
openlibrary/accounts/model.py:96
↓ 1 callersFunctionenrich_data
(_request_data)
openlibrary/plugins/openlibrary/pd.py:93
↓ 1 callersFunctionentity_decode
(text: str)
openlibrary/plugins/upstream/utils.py:609
↓ 1 callersFunctionescape_unknown_fields
Escapes the colon of any search field that is not deemed valid by the predicate function `is_valid_field`. :param query: Query to escape
openlibrary/solr/query_utils.py:65
↓ 1 callersFunctionevaluate_and_store_stat
Evaluates whether the given statistic is to be recorded and if so, records it.
openlibrary/plugins/openlibrary/stats.py:27
↓ 1 callersMethodexclude_book
(self, book: BookRecord)
scripts/providers/import_wikisource.py:163
↓ 1 callersFunctionexecute_solr_query_async
( solr_path: str, params: dict | list[tuple[str, Any]], _timeout: int | None = DEFAULT_SOLR_TIMEOU
openlibrary/plugins/worksearch/code.py:296
↓ 1 callersFunctionexpand
Expands keys like "/templates/*" to be all template keys. :param Disk or OpenLibrary server: :param typing.Iterable[str] keys: :retu
scripts/copydocs.py:90
↓ 1 callersFunctionexpand
(value)
openlibrary/plugins/ol_infobase.py:318
↓ 1 callersFunctionexpand_keys
(keys)
openlibrary/plugins/openlibrary/code.py:165
↓ 1 callersFunctionexposeGlobally
()
openlibrary/plugins/openlibrary/js/jsdef.js:167
↓ 1 callersFunctionextension
r"""jsdef extension. Adds support for `jsdef` block to template parser.:: >>> t = Template("$jsdef hello(name):\n Hello $name!", extensions=[e
openlibrary/plugins/upstream/jsdef.py:70
↓ 1 callersFunctionextract_item_metadata
(item_json: dict)
openlibrary/core/ia.py:106
↓ 1 callersFunctionf
(bib_key: str, doc: OpenLibraryEditionWithPreview)
openlibrary/plugins/books/dynlinks.py:448
↓ 1 callersMethodf
(editions)
openlibrary/tests/solr/updater/test_work.py:256
↓ 1 callersFunctionfetchCounts
* Fetches login counts from the server. * * @returns {Promise<Response>} * @see `monthly_logins` class in /openlibrary/plugins/openlibrary/api.py
openlibrary/plugins/openlibrary/js/stats/index.js:33
↓ 1 callersFunctionfetchOpenPullRequests
* Fetches and returns an array of all open pull requests for internetarchive/openlibrary. * * @returns {Promise<Array<Record>>}
scripts/gh_scripts/weekly_status_report.mjs:108
← previousnext →1,801–1,900 of 6,179, ranked by callers