### Configure npm Install Script with prebuild-install Options Source: https://github.com/joshuarileydev/app-store-connect-mcp-server/blob/main/node_modules/prebuild-install/README.md This JSON snippet demonstrates how to pass options to prebuild-install within the package.json 'install' script. In this example, the '-r napi' option specifies that prebuilt binaries for the Node-API runtime should be downloaded. Similar to the basic configuration, it falls back to 'node-gyp rebuild' if the prebuilt binary is not found. ```json { "scripts": { "install": "prebuild-install -r napi || node-gyp rebuild" } } ``` -------------------------------- ### Install prebuild-install using npm Source: https://github.com/joshuarileydev/app-store-connect-mcp-server/blob/main/node_modules/prebuild-install/README.md This is the standard command to install the `prebuild-install` package using npm. It downloads and installs the package and its dependencies into your project. ```bash npm install prebuild-install ``` -------------------------------- ### Axios Request Example with Promise Handling Source: https://github.com/joshuarileydev/app-store-connect-mcp-server/blob/main/node_modules/axios/README.md Demonstrates how to make a GET request using Axios and handle the response using Promises with `.then()`, logging various properties of the response object. ```javascript axios.get('/user/12345') .then(function (response) { console.log(response.data); console.log(response.status); console.log(response.statusText); console.log(response.headers); console.log(response.config); }); ``` -------------------------------- ### Node ABI JavaScript Usage Examples Source: https://github.com/joshuarileydev/app-store-connect-mcp-server/blob/main/node_modules/node-abi/README.md Demonstrates how to use the 'node-abi' package in JavaScript to get ABI versions from target versions and runtimes, and to get target versions from ABI versions. It also shows how to access lists of all, deprecated, supported, additional, and future targets. ```javascript const nodeAbi = require('node-abi') nodeAbi.getAbi('7.2.0', 'node') // '51' nodeAbi.getAbi('1.4.10', 'electron') // '50' nodeAbi.getTarget('51', 'node') // '7.2.0' nodeAbi.getTarget('50', 'electron') // '1.4.15' nodeAbi.allTargets // [ // { runtime: 'node', target: '0.10.48', abi: '11', lts: false }, // { runtime: 'node', target: '0.12.17', abi: '14', lts: false }, // { runtime: 'node', target: '4.6.1', abi: '46', lts: true }, // { runtime: 'node', target: '5.12.0', abi: '47', lts: false }, // { runtime: 'node', target: '6.9.4', abi: '48', lts: true }, // { runtime: 'node', target: '7.4.0', abi: '51', lts: false }, // { runtime: 'electron', target: '1.0.2', abi: '47', lts: false }, // { runtime: 'electron', target: '1.2.8', abi: '48', lts: false }, // { runtime: 'electron', target: '1.3.13', abi: '49', lts: false }, // { runtime: 'electron', target: '1.4.15', abi: '50', lts: false } // ] nodeAbi.deprecatedTargets nodeAbi.supportedTargets nodeAbi.additionalTargets nodeAbi.futureTargets // ... ``` -------------------------------- ### Install Axios using npm, bower, yarn, or pnpm Source: https://github.com/joshuarileydev/app-store-connect-mcp-server/blob/main/node_modules/axios/README.md These commands demonstrate how to install the Axios library using different package managers. After installation, Axios can be imported using ES6 import or CommonJS require syntax. ```bash $ npm install axios ``` ```bash $ bower install axios ``` ```bash $ yarn add axios ``` ```bash $ pnpm add axios ``` -------------------------------- ### Fetch Proxy URL and Make HTTP Request (JavaScript) Source: https://github.com/joshuarileydev/app-store-connect-mcp-server/blob/main/node_modules/proxy-from-env/README.md This JavaScript example demonstrates how to use `proxy-from-env` to get a proxy URL for a given target URL. It then constructs an HTTP request, either direct or proxied, based on the obtained proxy information. This showcases the core functionality of the package in a practical scenario. ```javascript var http = require('http'); var parseUrl = require('url').parse; var getProxyForUrl = require('proxy-from-env').getProxyForUrl; var some_url = 'http://example.com/something'; // // Example, if there is a proxy server at 10.0.0.1:1234, then setting the // // http_proxy environment variable causes the request to go through a proxy. // process.env.http_proxy = 'http://10.0.0.1:1234'; // // // But if the host to be proxied is listed in NO_PROXY, then the request is // // not proxied (but a direct request is made). // process.env.no_proxy = 'example.com'; var proxy_url = getProxyForUrl(some_url); // <-- Our magic. if (proxy_url) { // Should be proxied through proxy_url. var parsed_some_url = parseUrl(some_url); var parsed_proxy_url = parseUrl(proxy_url); // A HTTP proxy is quite simple. It is similar to a normal request, except the // path is an absolute URL, and the proxied URL's host is put in the header // instead of the server's actual host. httpOptions = { protocol: parsed_proxy_url.protocol, hostname: parsed_proxy_url.hostname, port: parsed_proxy_url.port, path: parsed_some_url.href, headers: { Host: parsed_some_url.host, // = host name + optional port. }, }; } else { // Direct request. httpOptions = some_url; } http.get(httpOptions, function(res) { var responses = []; res.on('data', function(chunk) { responses.push(chunk); }); res.on('end', function() { console.log(responses.join('')); }); }); ``` -------------------------------- ### Install semver via npm Source: https://github.com/joshuarileydev/app-store-connect-mcp-server/blob/main/node_modules/semver/README.md This command installs the semver package using npm, the Node Package Manager. Ensure you have Node.js and npm installed on your system. ```bash npm install semver ``` -------------------------------- ### Install App Store Connect MCP Server using Smithery CLI Source: https://github.com/joshuarileydev/app-store-connect-mcp-server/blob/main/README.md This command installs the App Store Connect MCP Server for Claude Desktop using the Smithery command-line interface. It simplifies the installation process for users who want to integrate the server with their Claude environment. ```bash npx @smithery/cli install appstore-connect-mcp-server --client claude ``` -------------------------------- ### Configure npm Install Script with prebuild-install Source: https://github.com/joshuarileydev/app-store-connect-mcp-server/blob/main/node_modules/prebuild-install/README.md This JSON snippet shows how to configure the 'install' script in a package.json file to use prebuild-install. If prebuild-install fails to find a suitable prebuilt binary, it will fall back to 'node-gyp rebuild' to build from source. This ensures that the package can be installed even without prebuilt binaries available for the specific environment. ```json { "scripts": { "install": "prebuild-install || node-gyp rebuild" } } ``` -------------------------------- ### Install App Store Connect MCP Server using npm Source: https://github.com/joshuarileydev/app-store-connect-mcp-server/blob/main/README.md This command installs the App Store Connect MCP Server package from npm. This is the manual installation method, suitable for direct integration into Node.js projects. ```bash npm install @joshuarileydev/app-store-connect-mcp-server ``` -------------------------------- ### Install queue-tick using npm Source: https://github.com/joshuarileydev/app-store-connect-mcp-server/blob/main/node_modules/queue-tick/README.md This command installs the queue-tick package from npm, making it available for use in your project. No specific inputs or outputs are associated with this installation command. ```bash npm install queue-tick ``` -------------------------------- ### Install Node.js Addon API Dependency Source: https://github.com/joshuarileydev/app-store-connect-mcp-server/blob/main/node_modules/node-addon-api/tools/README.md Installs the 'node-addon-api' package, which is a prerequisite for running the migration script. This command should be executed in the project's root directory. ```bash npm install node-addon-api ``` -------------------------------- ### Install base64-js with npm Source: https://github.com/joshuarileydev/app-store-connect-mcp-server/blob/main/node_modules/base64-js/README.md Installs the base64-js library using npm and shows how to require it in your JavaScript project. This is the recommended method for Node.js environments. ```javascript npm install base64-js var base64js = require('base64-js') ``` -------------------------------- ### Install napi-build-utils Source: https://github.com/joshuarileydev/app-store-connect-mcp-server/blob/main/node_modules/napi-build-utils/README.md Installs the napi-build-utils package using npm. This package provides utilities for building N-API native add-ons. ```bash npm install napi-build-utils ``` -------------------------------- ### Install github-from-package with npm Source: https://github.com/joshuarileydev/app-store-connect-mcp-server/blob/main/node_modules/github-from-package/readme.markdown This command installs the 'github-from-package' module using npm, making it available for use in your Node.js project. ```bash npm install github-from-package ``` -------------------------------- ### Install mimic-response via npm Source: https://github.com/joshuarileydev/app-store-connect-mcp-server/blob/main/node_modules/mimic-response/readme.md This command installs the mimic-response package using npm, making it available for use in your Node.js project. Ensure you have Node.js and npm installed. ```bash npm install mimic-response ``` -------------------------------- ### Install unpipe using npm Source: https://github.com/joshuarileydev/app-store-connect-mcp-server/blob/main/node_modules/unpipe/README.md Installs the 'unpipe' package from the npm registry. This is the primary method for incorporating the library into a Node.js project. ```sh npm install unpipe ``` -------------------------------- ### Install Sharp Module Source: https://github.com/joshuarileydev/app-store-connect-mcp-server/blob/main/node_modules/sharp/README.md Installs the 'sharp' Node.js module using npm. This is a prerequisite for using the library in your project. ```sh npm install sharp ``` -------------------------------- ### Install raw-body Node.js Module Source: https://github.com/joshuarileydev/app-store-connect-mcp-server/blob/main/node_modules/raw-body/README.md Installs the raw-body Node.js module using npm. This is a prerequisite for using the module in your project. ```bash npm install raw-body ``` -------------------------------- ### Install StreamX Package Source: https://github.com/joshuarileydev/app-store-connect-mcp-server/blob/main/node_modules/streamx/README.md Installs the streamx package using npm. This is the first step to using the library in a Node.js project. ```bash npm install streamx ``` -------------------------------- ### Install TypeScript Stable Version Source: https://github.com/joshuarileydev/app-store-connect-mcp-server/blob/main/node_modules/typescript/README.md Installs the latest stable version of TypeScript as a development dependency using npm. This is the recommended way to get the most current, production-ready release. ```bash npm install -D typescript ``` -------------------------------- ### Express Example: Get Raw Request Body Source: https://github.com/joshuarileydev/app-store-connect-mcp-server/blob/main/node_modules/raw-body/README.md A simple Express.js middleware example demonstrating how to use `getRawBody` to retrieve the raw request body as a string, with specified length, limit, and encoding options derived from the request's content type. ```javascript var contentType = require('content-type') var express = require('express') var getRawBody = require('raw-body') var app = express() app.use(function (req, res, next) { getRawBody(req, { length: req.headers['content-length'], limit: '1mb', encoding: contentType.parse(req).parameters.charset }, function (err, string) { if (err) return next(err) req.text = string next() }) }) // now access req.text ``` -------------------------------- ### Get Response Data as a Buffer Source: https://github.com/joshuarileydev/app-store-connect-mcp-server/blob/main/node_modules/simple-get/README.md This example shows how to retrieve the entire response body as a Buffer using 'simple-get.concat'. This is useful when the response is expected to be small and you need direct access to the data without dealing with streams. Error handling is included. ```javascript const get = require('simple-get') get.concat('http://example.com', function (err, res, data) { if (err) throw err console.log(res.statusCode) // 200 console.log(data) // Buffer('this is the server response') }) ``` -------------------------------- ### Override Binary Download Location with Custom Host Source: https://github.com/joshuarileydev/app-store-connect-mcp-server/blob/main/node_modules/prebuild-install/README.md This example demonstrates how to configure a custom host for downloading prebuilt binaries using environment variables in an `.npmrc` file. The variable format is `% your package name %_binary_host` or `% your package name %_binary_host_mirror`. The package version and filename are automatically appended to the provided host path. ```ini leveldown_binary_host=http://overriden-host.com/overriden-path ``` -------------------------------- ### Node.js Migration Script - Class Initialization Source: https://github.com/joshuarileydev/app-store-connect-mcp-server/blob/main/node_modules/node-addon-api/tools/README.md Illustrates how to initialize a class, define its methods, accessors, and static methods within the Napi framework. This includes setting up instance methods, accessors, static methods, and instance values. ```cpp Napi::FunctionReference constructor; void [ClassName]::Init(Napi::Env env, Napi::Object exports, Napi::Object module) { Napi::HandleScope scope(env); Napi::Function ctor = DefineClass(env, "Canvas", { InstanceMethod<&[ClassName]::Func1>("Func1"), InstanceMethod<&[ClassName]::Func2>("Func2"), InstanceAccessor<&[ClassName]::ValueGetter>("Value"), StaticMethod<&[ClassName]::StaticMethod>("MethodName"), InstanceValue("Value", Napi::[Type]::New(env, value)), }); constructor = Napi::Persistent(ctor); constructor .SuppressDestruct(); exports.Set("[ClassName]", ctor); } ``` -------------------------------- ### Koa Example: Get Raw Request Body Source: https://github.com/joshuarileydev/app-store-connect-mcp-server/blob/main/node_modules/raw-body/README.md A simple Koa.js middleware example using generator functions to demonstrate how to use `getRawBody` to retrieve the raw request body as a string, with specified length, limit, and encoding options derived from the request's content type. ```javascript var contentType = require('content-type') var getRawBody = require('raw-body') var koa = require('koa') var app = koa() app.use(function * (next) { this.text = yield getRawBody(this.req, { length: this.req.headers['content-length'], limit: '1mb', encoding: contentType.parse(this.req).parameters.charset }) yield next }) // now access this.text ``` -------------------------------- ### Configure Private GitHub Repository Access with prebuild-install Source: https://github.com/joshuarileydev/app-store-connect-mcp-server/blob/main/node_modules/prebuild-install/README.md This snippet shows how to use a GitHub token with the `prebuild-install` tool to download prebuilds from private repositories. The token can be provided via CLI argument, a configuration file (`~/.prebuild-installrc`), or an environment variable. Note that using a GitHub token is subject to GitHub's API rate limits. ```shell $ prebuild-install -T ``` ```bash token= ``` ```shell export PREBUILD_INSTALL_TOKEN= ``` -------------------------------- ### Create Signed OAuth 1.0a Request Source: https://github.com/joshuarileydev/app-store-connect-mcp-server/blob/main/node_modules/simple-get/README.md This example shows how to create a signed OAuth 1.0a request using the 'oauth-1.0a' and 'crypto' modules. It requires environment variables for consumer and access tokens. The input is API endpoint details and token secrets, and the output is a GET request with an authorized header. ```javascript const get = require('simple-get') const crypto = require('crypto') const OAuth = require('oauth-1.0a') const oauth = OAuth({ consumer: { key: process.env.CONSUMER_KEY, secret: process.env.CONSUMER_SECRET }, signature_method: 'HMAC-SHA1', hash_function: (baseString, key) => crypto.createHmac('sha1', key).update(baseString).digest('base64') }) const token = { key: process.env.ACCESS_TOKEN, secret: process.env.ACCESS_TOKEN_SECRET } const url = 'https://api.twitter.com/1.1/statuses/home_timeline.json' const opts = { url: url, headers: oauth.toHeader(oauth.authorize({url, method: 'GET'}, token)), json: true } get(opts, function (err, res) {}) ``` -------------------------------- ### Clone and Install Project Repository Source: https://github.com/joshuarileydev/app-store-connect-mcp-server/blob/main/node_modules/iconv-lite/README.md This command sequence clones the project repository from GitHub, navigates into the project directory, and installs the necessary npm dependencies. ```bash git clone git@github.com:ashtuchkin/iconv-lite.git cd iconv-lite npm install ``` -------------------------------- ### Using Proxies with HTTP Over HTTP Source: https://github.com/joshuarileydev/app-store-connect-mcp-server/blob/main/node_modules/simple-get/README.md This example shows how to configure 'simple-get' to use a proxy server for HTTP requests. It utilizes the 'tunnel' module to establish an HTTP-over-HTTP proxy connection, specifying the proxy host. ```javascript const get = require('simple-get') const tunnel = require('tunnel') const opts = { url: 'http://example.com', agent: tunnel.httpOverHttp({ proxy: { host: 'localhost' } }) } get(opts, function (err, res) {}) ``` -------------------------------- ### Set Request Timeout Source: https://github.com/joshuarileydev/app-store-connect-mcp-server/blob/main/node_modules/simple-get/README.md This example demonstrates how to set a timeout for an HTTP request using the 'timeout' option. If the request exceeds the specified duration in milliseconds, it will be aborted and an error will be thrown, preventing indefinitely long requests. ```javascript const get = require('simple-get') const opts = { url: 'http://example.com', timeout: 2000 // 2 second timeout } get(opts, function (err, res) {}) ``` -------------------------------- ### Send 'application/x-www-form-urlencoded' Form Data Manually Source: https://github.com/joshuarileydev/app-store-connect-mcp-server/blob/main/node_modules/simple-get/README.md This example shows how to send form data with the 'application/x-www-form-urlencoded' content type manually. It uses the 'simple-get' module. The input is an object containing key-value pairs, and it makes a POST request to a specified URL. ```javascript const get = require('simple-get') const opts = { url: 'http://example.com', form: { key: 'value' } } get.post(opts, function (err, res) {}) ``` -------------------------------- ### bare-fs Usage Examples Source: https://github.com/joshuarileydev/app-store-connect-mcp-server/blob/main/node_modules/bare-fs/README.md Demonstrates the usage of the bare-fs module by importing it and listing its supported functions. This includes core file system operations, promise-based APIs, synchronous methods, and stream creation utilities. ```javascript const fs = require('bare-fs') // Currently supports: fs.access fs.chmod fs.close fs.chmod fs.exists fs.fstat fs.ftruncate fs.lstat fs.mkdir fs.open fs.opendir fs.read fs.readdir fs.readlink fs.readv fs.realpath fs.rename fs.rmdir fs.stat fs.symlink fs.unlink fs.watch fs.write fs.writev fs.appendFile fs.readFile fs.writeFile fs.promises.access fs.promises.chmod fs.promises.lstat fs.promises.mkdir fs.promises.opendir fs.promises.readdir fs.promises.readlink fs.promises.realpath fs.promises.rename fs.promises.rmdir fs.promises.stat fs.promises.symlink fs.promises.unlink fs.promises.watch fs.promises.appendFile fs.promises.readFile fs.promises.writeFile fs.createReadStream fs.createWriteStream fs.accessSync fs.chmodSync fs.closeSync fs.existsSync fs.fchmodSync fs.fstatSync fs.lstatSync fs.mkdirSync fs.openSync fs.opendirSync fs.readSync fs.readdirSync fs.readlinkSync fs.realpathSync fs.renameSync fs.rmdirSync fs.statSync fs.symlinkSync fs.unlinkSync fs.writeSync fs.appendFileSync fs.readFileSync fs.writeFileSync ``` -------------------------------- ### Advanced POST Request with Headers and Timeout Source: https://github.com/joshuarileydev/app-store-connect-mcp-server/blob/main/node_modules/simple-get/README.md This more complex example demonstrates making a POST request with custom headers and setting a request timeout. It also highlights that 'simple-get' accepts all Node.js 'http' request options and that the response object retains properties of http.IncomingMessage, even after decompression. ```javascript const get = require('simple-get') get({ url: 'http://example.com', method: 'POST', body: 'this is the POST body', // simple-get accepts all options that node.js `http` accepts // See: http://nodejs.org/api/http.html#http_http_request_options_callback headers: { 'user-agent': 'my cool app' } }, function (err, res) { if (err) throw err // All properties/methods from http.IncomingResponse are available, // even if a gunzip/inflate transform stream was returned. // See: http://nodejs.org/api/http.html#http_http_incomingmessage res.setTimeout(10000) console.log(res.headers) res.on('data', function (chunk) { // `chunk` is the decoded response, after it's been gunzipped or inflated // (if applicable) console.log('got a chunk of the response: ' + chunk) })) }) ``` -------------------------------- ### Install Project Dependencies Source: https://github.com/joshuarileydev/app-store-connect-mcp-server/blob/main/README.md Installs the necessary dependencies for the App Store Connect MCP Server project using npm. This is a standard step in setting up the development environment. ```bash npm install ``` -------------------------------- ### Install ShellJS using npm Source: https://github.com/joshuarileydev/app-store-connect-mcp-server/blob/main/node_modules/shelljs/README.md Installs the ShellJS library using npm. The '-g' flag installs it globally, making it available system-wide. Without '-g', it installs locally to the current project. ```bash npm install [-g] shelljs ``` -------------------------------- ### Build the Project Source: https://github.com/joshuarileydev/app-store-connect-mcp-server/blob/main/README.md Compiles and builds the App Store Connect MCP Server project. This command is typically used after installing dependencies or making code changes. ```bash npm run build ``` -------------------------------- ### Install lodash.once with npm Source: https://github.com/joshuarileydev/app-store-connect-mcp-server/blob/main/node_modules/lodash.once/README.md Installs lodash.once globally and as a project dependency using npm. Ensure Node.js and npm are installed. ```bash npm i -g npm npm i --save lodash.once ``` -------------------------------- ### Running Node-addon-api Benchmarks Source: https://github.com/joshuarileydev/app-store-connect-mcp-server/blob/main/node_modules/node-addon-api/README.md Command to execute the available benchmarks for the node-addon-api library. Further details can be found in the benchmark/README.md file. ```bash npm run-script benchmark ``` -------------------------------- ### Install lodash.includes via npm Source: https://github.com/joshuarileydev/app-store-connect-mcp-server/blob/main/node_modules/lodash.includes/README.md Demonstrates how to install the lodash.includes npm package globally and as a project dependency. Assumes npm is installed. ```bash {sudo -H} npm i -g npm $ npm i --save lodash.includes ``` -------------------------------- ### JSON Configuration File Example Source: https://github.com/joshuarileydev/app-store-connect-mcp-server/blob/main/node_modules/rc/README.md An example of a configuration file formatted using JSON. This format also supports comments (which are stripped) and nested structures. 'rc' automatically detects and parses JSON files. No file extension is needed. ```json { // You can even comment your JSON, if you want "dependsOn": "0.10.0", "commands": { "www": "./commands/www", "console": "./commands/repl" }, "generators": { "options": { "engine": "ejs" }, "modules": { "new": "generate-new", "backend": "generate-backend" } } } ``` -------------------------------- ### Install lodash.isnumber using npm Source: https://github.com/joshuarileydev/app-store-connect-mcp-server/blob/main/node_modules/lodash.isnumber/README.md Installs the lodash.isnumber package globally and then as a project dependency using npm. Assumes npm is already installed. ```bash {sudo -H} npm i -g npm npm i --save lodash.isnumber ``` -------------------------------- ### Quick Start MCP Server with TypeScript Source: https://github.com/joshuarileydev/app-store-connect-mcp-server/blob/main/node_modules/@modelcontextprotocol/sdk/README.md Sets up a basic MCP server using the TypeScript SDK. It registers an addition tool and a dynamic greeting resource. The server then connects to a stdio transport to handle messages. ```typescript import { McpServer, ResourceTemplate } from "@modelcontextprotocol/sdk/server/mcp.js"; import { StdioServerTransport } from "@modelcontextprotocol/sdk/server/stdio.js"; import { z } from "zod"; // Create an MCP server const server = new McpServer({ name: "demo-server", version: "1.0.0" }); // Add an addition tool server.registerTool("add", { title: "Addition Tool", description: "Add two numbers", inputSchema: { a: z.number(), b: z.number() } }, async ({ a, b }) => ({ content: [{ type: "text", text: String(a + b) }] }) ); // Add a dynamic greeting resource server.registerResource( "greeting", new ResourceTemplate("greeting://{name}", { list: undefined }), { title: "Greeting Resource", // Display name for UI description: "Dynamic greeting generator" }, async (uri, { name }) => ({ contents: [{ uri: uri.href, text: `Hello, ${name}!` }] }) ); // Start receiving messages on stdin and sending messages on stdout const transport = new StdioServerTransport(); await server.connect(transport); ``` -------------------------------- ### Install node-jws Package Source: https://github.com/joshuarileydev/app-store-connect-mcp-server/blob/main/node_modules/jws/readme.md This command installs the node-jws library using npm, the Node Package Manager. Ensure you have Node.js and npm installed on your system. ```bash npm install jws ``` -------------------------------- ### Get Index Range of First Balanced Pair with balanced.range() in JavaScript Source: https://github.com/joshuarileydev/app-store-connect-mcp-server/blob/main/node_modules/balanced-match/README.md This snippet illustrates the usage of `balanced.range()`, which returns an array containing the start and end indices of the first non-nested matching pair of delimiters in a string. Similar to `balanced()`, it supports literal strings and regular expressions as delimiters. If no match is found, it returns `undefined`. The behavior for unmatched pairs is consistent, prioritizing the first closed match. ```javascript var balanced = require('balanced-match'); console.log(balanced.range('{', '}', 'pre{in{nested}}post')); console.log(balanced.range('', '', 'bold and italic')); console.log(balanced.range('(', ')', 'first (nested (parens)) second')); ``` -------------------------------- ### INI Configuration File Example Source: https://github.com/joshuarileydev/app-store-connect-mcp-server/blob/main/node_modules/rc/README.md An example of a configuration file formatted using the INI syntax. This format supports comments and nested sections, which 'rc' can parse. No file extension is needed for 'rc' to recognize the format. ```ini ; You can include comments in `ini` format if you want. dependsOn=0.10.0 ; `rc` has built-in support for ini sections, see? [commands] www = ./commands/www console = ./commands/repl ; You can even do nested sections [generators.options] engine = ejs [generators.modules] new = generate-new engine = generate-backend ``` -------------------------------- ### Install lodash.isboolean using npm Source: https://github.com/joshuarileydev/app-store-connect-mcp-server/blob/main/node_modules/lodash.isboolean/README.md This snippet shows how to install the lodash.isboolean package globally and as a project dependency using npm. It requires Node.js and npm to be installed. ```bash npm i -g npm npm i --save lodash.isboolean ``` -------------------------------- ### Install and use .equal() method on Buffer prototypes in JavaScript Source: https://github.com/joshuarileydev/app-store-connect-mcp-server/blob/main/node_modules/buffer-equal-constant-time/README.md Shows how to install a constant-time `.equal()` method onto the Node.js Buffer and SlowBuffer prototypes using buffer-equal-constant-time.install(). This allows direct comparison using the method on buffer instances. ```javascript require('buffer-equal-constant-time').install(); var a = new Buffer('asdf'); var b = new Buffer('asdf'); if (a.equal(b)) { // the same! } else { // different in at least one byte! } ``` -------------------------------- ### Basic Usage of fast-fifo Source: https://github.com/joshuarileydev/app-store-connect-mcp-server/blob/main/node_modules/fast-fifo/README.md Demonstrates the fundamental usage of the FIFO class. It shows how to instantiate a new FIFO queue, push elements onto it, and then retrieve them using the shift method. ```javascript const FIFO = require('fast-fifo') const q = new FIFO() q.push('hello') q.push('world') q.shift() // returns hello q.shift() // returns world ``` -------------------------------- ### Install bare-events npm Package Source: https://github.com/joshuarileydev/app-store-connect-mcp-server/blob/main/node_modules/bare-events/README.md Installs the bare-events library using npm. This is the first step to using event emitters in your JavaScript project. Ensure you have Node.js and npm installed. ```bash npm install bare-events ``` -------------------------------- ### Usage Examples for path-is-absolute Source: https://github.com/joshuarileydev/app-store-connect-mcp-server/blob/main/node_modules/path-is-absolute/readme.md Demonstrates how to use the 'path-is-absolute' package to check if a given path is absolute. It includes examples for Linux, Windows, and OS-agnostic checks using .posix and .win32 methods. ```javascript const pathIsAbsolute = require('path-is-absolute'); // Running on Linux pathIsAbsolute('/home/foo'); //=> true pathIsAbsolute('C:/Users/foo'); //=> false // Running on Windows pathIsAbsolute('C:/Users/foo'); //=> true pathIsAbsolute('/home/foo'); //=> false // Running on any OS pathIsAbsolute.posix('/home/foo'); //=> true pathIsAbsolute.posix('C:/Users/foo'); //=> false pathIsAbsolute.win32('C:/Users/foo'); //=> true pathIsAbsolute.win32('/home/foo'); //=> false ``` -------------------------------- ### Install bare-path via npm Source: https://github.com/joshuarileydev/app-store-connect-mcp-server/blob/main/node_modules/bare-path/README.md This snippet demonstrates how to install the bare-path library using npm, the Node Package Manager. No specific inputs or outputs are associated with this installation command. ```bash npm i bare-path ``` -------------------------------- ### Create Custom Axios Instance Source: https://github.com/joshuarileydev/app-store-connect-mcp-server/blob/main/node_modules/axios/README.md Shows how to create a custom instance of axios with a predefined configuration, such as a base URL, timeout, and custom headers. This allows for reusing common settings across multiple requests. ```javascript const instance = axios.create({ baseURL: 'https://some-domain.com/api/', timeout: 1000, headers: {'X-Custom-Header': 'foobar'} }); ``` -------------------------------- ### Find First Balanced String Pair with balanced() in JavaScript Source: https://github.com/joshuarileydev/app-store-connect-mcp-server/blob/main/node_modules/balanced-match/README.md This example demonstrates how to use the `balanced()` function to find the first non-nested matching pair of delimiters in a string. It can handle literal string delimiters and regular expressions. The function returns an object with the start and end indices, preamble, body, and postscript of the match, or undefined if no match is found. It correctly handles nested structures by matching the first closed pair. ```javascript var balanced = require('balanced-match'); console.log(balanced('{', '}', 'pre{in{nested}}post')); console.log(balanced('{', '}', 'pre{first}between{second}post')); console.log(balanced(/\s+\{\s+/, /\s+\}\s+/, 'pre { in{nest} } post')); ``` -------------------------------- ### Install content-type package Source: https://github.com/joshuarileydev/app-store-connect-mcp-server/blob/main/node_modules/content-type/README.md Installs the 'content-type' npm package. This is the primary dependency for using the library. ```sh npm install content-type ``` -------------------------------- ### Run Node.js Migration Script Source: https://github.com/joshuarileydev/app-store-connect-mcp-server/blob/main/node_modules/node-addon-api/tools/README.md Executes the conversion script located in the 'node-addon-api' module to assist with code migration. This script requires the project directory path as an argument. ```bash node ./node_modules/node-addon-api/tools/conversion.js ./ ``` -------------------------------- ### Install setprototypeof via npm Source: https://github.com/joshuarileydev/app-store-connect-mcp-server/blob/main/node_modules/setprototypeof/README.md This command installs the `setprototypeof` package as a dependency for your project. ```bash npm install --save setprototypeof ``` -------------------------------- ### Echo Server Example using McpServer SDK Source: https://github.com/joshuarileydev/app-store-connect-mcp-server/blob/main/node_modules/@modelcontextprotocol/sdk/README.md Demonstrates how to set up an echo server using the ModelContextProtocol (MCP) SDK. This example registers an 'echo' resource, tool, and prompt, showcasing how to handle different types of MCP interactions. It utilizes Zod for input schema validation. ```typescript import { McpServer, ResourceTemplate } from "@modelcontextprotocol/sdk/server/mcp.js"; import { z } from "zod"; const server = new McpServer({ name: "echo-server", version: "1.0.0" }); server.registerResource( "echo", new ResourceTemplate("echo://{message}", { list: undefined }), { title: "Echo Resource", description: "Echoes back messages as resources" }, async (uri, { message }) => ({ contents: [{ uri: uri.href, text: `Resource echo: ${message}` }] }) ); server.registerTool( "echo", { title: "Echo Tool", description: "Echoes back the provided message", inputSchema: { message: z.string() } }, async ({ message }) => ({ content: [{ type: "text", text: `Tool echo: ${message}` }] }) ); server.registerPrompt( "echo", { title: "Echo Prompt", description: "Creates a prompt to process a message", argsSchema: { message: z.string() } }, ({ message }) => ({ messages: [{ role: "user", content: { type: "text", text: `Please process this message: ${message}` } }] }) ); ``` -------------------------------- ### Install ecdsa-sig-formatter Source: https://github.com/joshuarileydev/app-store-connect-mcp-server/blob/main/node_modules/ecdsa-sig-formatter/README.md Installs the ecdsa-sig-formatter package as a project dependency using npm. ```sh npm install ecdsa-sig-formatter --save ``` -------------------------------- ### npm Installation Command Source: https://github.com/joshuarileydev/app-store-connect-mcp-server/blob/main/node_modules/brace-expansion/README.md Provides the command to install the `brace-expansion` library using npm, the Node Package Manager. This is a standard step for integrating the library into a Node.js project. ```bash npm install brace-expansion ``` -------------------------------- ### Install http-errors Package Source: https://github.com/joshuarileydev/app-store-connect-mcp-server/blob/main/node_modules/http-errors/README.md Install the http-errors package using npm. This is a Node.js module available through the npm registry. ```bash npm install http-errors ``` -------------------------------- ### JavaScript Configuration Loading with 'rc' Source: https://github.com/joshuarileydev/app-store-connect-mcp-server/blob/main/node_modules/rc/README.md This snippet shows a basic setup using the 'rc' module to load configuration. It defines default values and demonstrates how external configuration files and command-line arguments can override these defaults. The precedence order is typically: command-line arguments > environment variables > configuration files > defaults. ```javascript const conf = require('rc')('myapp', { port: 12345, mode: 'test' }); console.log(JSON.stringify(conf, null, 2)); ``` -------------------------------- ### Install and Use Glob for File Matching (JavaScript) Source: https://github.com/joshuarileydev/app-store-connect-mcp-server/blob/main/node_modules/glob/README.md Installs the glob library using npm and demonstrates its basic usage for finding files matching a pattern asynchronously. It shows how to require the module, define a pattern, and handle the results or errors in a callback function. The `nonull` option is mentioned for returning the pattern itself if no files are found. ```javascript npm i glob var glob = require("glob") // options is optional glob("**/*.js", options, function (er, files) { // files is an array of filenames. // If the `nonull` option is set, and nothing // was found, then files is ["**/*.js"] // er is an error object or null. }) ```